mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-19 20:38:08 +01:00
Remove dead code for a confirmation dialog that we'll probably never want to show
Setting a clip as autoattracting will disable an autoattracting drawer, and reciprocally. Although not immediately obvious, it should be fairly easy to figure out, and is totally reversible. So we'll probably never opt to show that confirmation dialog box.
This commit is contained in:
committed by
Carlos R. Mafra
parent
45799efa02
commit
f53797f9ef
26
src/dock.c
26
src/dock.c
@@ -583,32 +583,6 @@ static void toggleAutoAttractCallback(WMenu *menu, WMenuEntry *entry)
|
||||
|
||||
assert(entry->clientdata != NULL);
|
||||
|
||||
/* Setting a clip as autoattracting will disable an autoattracting drawer,
|
||||
* and reciprocally. Ask for confirmation? */
|
||||
#ifdef CONFIRM_AUTOATTRACT_CHANGE
|
||||
if (dock->type == WM_CLIP && scr->attracting_drawer) {
|
||||
if (wMessageDialog(scr, _("Workspace Clip"),
|
||||
_("The drawer that auto-attracted icons so far won't do so anymore!"),
|
||||
_("OK"), _("Cancel"), NULL) != WAPRDefault)
|
||||
return;
|
||||
} else if (dock->type == WM_DRAWER) {
|
||||
/* check if at least one clip already auto attracts icons */
|
||||
int i, ask_for_confirmation = False;
|
||||
for (i = 0; i < w_global.workspace.count; i++) {
|
||||
if (w_global.workspace.array[i]->clip->attract_icons) {
|
||||
ask_for_confirmation = True;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (ask_for_confirmation) {
|
||||
if (wMessageDialog(scr, _("Drawer"),
|
||||
_("Any clips that auto-attracted icons so far won't do so anymore!"),
|
||||
_("OK"), _("Cancel"), NULL) != WAPRDefault)
|
||||
return;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
dock->attract_icons = !dock->attract_icons;
|
||||
|
||||
entry->flags.indicator_on = dock->attract_icons;
|
||||
|
||||
Reference in New Issue
Block a user