Created
July 16, 2017 17:33
-
-
Save lexruee/b73c52d0174f315395dfbdde07e9808d to your computer and use it in GitHub Desktop.
disable suspend button feature
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let disableSuspendButtonFrame = new AM.FrameBox(); | |
let disableSuspendButtonRow = new AM.FrameBoxRow(); | |
let disableSuspendButtonLabel = new Gtk.Label({ | |
label: _("Disable activities hot corner"), | |
use_markup: true, | |
xalign: 0, | |
hexpand: true | |
}); | |
let disableSuspendButtonSwitch = new Gtk.Switch({ halign: Gtk.Align.END }); | |
disableSuspendButtonSwitch.set_active(this.settings.get_boolean('disable-suspend-button')); | |
disableSuspendButtonSwitch.connect('notify::active', Lang.bind(this, function(check) { | |
this.settings.set_boolean('disable-suspend-button', check.get_active()); | |
})); | |
disableSuspendButtonRow.add(disableSuspendButtonLabel); | |
disableSuspendButtonRow.add(disableSuspendButtonSwitch); | |
disableSuspendButtonFrame.add(disableSuspendButtonSwitch); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<key type="b" name="disable-suspend-button"> | |
<default>false</default> | |
<summary>Disable suspend button</summary> | |
<description>Disable suspend button.</description> | |
</key> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment