mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-19 20:38:08 +01:00
Add option to allow starting DockApps with a single click
This patch is from the contrib directory. It adds an option to allow starting DockApps with a single click. It's a handy option that adds only a few lines to the code. It is a good feature patch example because it includes modifications to the WPrefs application so that the feature can be easily enabled or disabled. The one-click ability allows wmaker to integrate more seemlessly with programs like ROX-Filer which can be configured to use single or double click actions. The README in the contrib/ directory says, author: Sebastien Bauer <seb_bauer@bigfoot.com> John Morrissey <jwm@horde.net> updated for Window Maker 0.65.0 by: Daniel Richard G. <skunk@graphics.lcs.mit.edu> updated for Window Maker 0.80.2 by: Martial Daumas <martial@nasgaia.org> update for 0.80.2+ by: steve lion <steve.lion@verizon.net> and vlaad
This commit is contained in:
committed by
Carlos R. Mafra
parent
c04a2caeab
commit
f8dd3dc49e
@@ -49,6 +49,7 @@ static void showData(_Panel * panel)
|
||||
WMSetButtonSelected(panel->swi[4], GetBoolForKey("DontConfirmKill"));
|
||||
WMSetButtonSelected(panel->swi[5], GetBoolForKey("DisableBlinking"));
|
||||
WMSetButtonSelected(panel->swi[6], GetBoolForKey("AntialiasedText"));
|
||||
WMSetButtonSelected(panel->swi[7], GetBoolForKey("SingleClickLaunch"));
|
||||
}
|
||||
|
||||
static void createPanel(Panel * p)
|
||||
@@ -59,7 +60,7 @@ static void createPanel(Panel * p)
|
||||
panel->box = WMCreateBox(panel->parent);
|
||||
WMSetViewExpandsToParent(WMWidgetView(panel->box), 2, 2, 2, 2);
|
||||
|
||||
for (i = 0; i < 7; i++) {
|
||||
for (i = 0; i < 8; i++) {
|
||||
panel->swi[i] = WMCreateSwitchButton(panel->box);
|
||||
WMResizeWidget(panel->swi[i], FRAME_WIDTH - 40, 25);
|
||||
WMMoveWidget(panel->swi[i], 20, 20 + i * 25);
|
||||
@@ -73,6 +74,7 @@ static void createPanel(Panel * p)
|
||||
WMSetButtonText(panel->swi[4], _("Disable confirmation panel for the Kill command."));
|
||||
WMSetButtonText(panel->swi[5], _("Disable selection animation for selected icons."));
|
||||
WMSetButtonText(panel->swi[6], _("Smooth font edges (needs restart)."));
|
||||
WMSetButtonText(panel->swi[7], _("Launch applications and restore windows with a single click."));
|
||||
|
||||
WMSetButtonEnabled(panel->swi[6], True);
|
||||
|
||||
@@ -95,6 +97,7 @@ static void storeDefaults(_Panel * panel)
|
||||
SetBoolForKey(WMGetButtonSelected(panel->swi[4]), "DontConfirmKill");
|
||||
SetBoolForKey(WMGetButtonSelected(panel->swi[5]), "DisableBlinking");
|
||||
SetBoolForKey(WMGetButtonSelected(panel->swi[6]), "AntialiasedText");
|
||||
SetBoolForKey(WMGetButtonSelected(panel->swi[7]), "SingleClickLaunch");
|
||||
}
|
||||
|
||||
Panel *InitExpert(WMScreen * scr, WMWidget * parent)
|
||||
|
||||
Reference in New Issue
Block a user