diff --git a/NEWS b/NEWS index c47fb593..fa70c52e 100644 --- a/NEWS +++ b/NEWS @@ -74,14 +74,49 @@ Omnipresent icons in Clip ------------------------- Added ability to set icons docked in Clip to be omnipresent on all workspaces. -To set/reset this flag use the "Settings Panel" for that specific icon (right -click on docked icon, and select "Settings"). +To set/reset this flag use the clip menu. +The Clip menu changed in the following way: + - if you bring up the menu from the Clip's main icon, it will contain as + before the "Rename Workspace" entry in the second position. + - however, if you bring up the menu from any other icon in clip, the + "Rename Workspace" menu entry is replaced by "Omnipresent" or + "Toggle Omnipresent" depending on the context. + +This entry will work in the following way, depending on the context: + +1. If there is no icon selected in the clip, then the menu will contain the + entry named "Omnipresent" which will be checked accordingly to the current + state of the icon (omnipresent or not), and will let you change the + omnipresent state of the icon you brought the menu from. +2. If one or more icons are already selected when the Clip menu is called, the + entry will be named "Toggle Omnipresent" and will apply to all selected + icons trying to toggle their omnipresent state. The icons which will be + succesfully changed to their new state as requested, will be unselected, + while the ones that will fail for some reason to gain their new state, + will remain selected. + +In both cases if there is not success in setting what user requested a panel +will inform user of the failure. +(Note: trying to set an icon to not-omnipresent will never fail. Failures can + be met only when trying to set omnipresent for an icon). + +The icons set to omnipresent will be marked with a triangle in the upper left +corner, having the color of the IconTitleColor. + An icon can be set to omnipresent, only if its position is free in all the workspaces, else you will be informed of the problem and asked to fix it first. Also when dragging an omnipresent icon around in Clip, all the icons docked in all the workspaces are shown while the dragging is done, to let one easily see where are free slots in all workspaces. +For advanced users, there is also a shortcut to set/reset the omnipresent +state of an icon: just use "Shift+MiddleButton" (button2) on the icon you want +to change. +In this case only the mark in the upper left corner will appear in case of +success, or nothing will happen if icon cannot be made omnipresent (advanced +users are expected to know why the icon failed to be made omnipresent, so they +don't need a panel to explain them why ;) ). + Now before you load your gun to start a flame war because this is against your principles you love so much, please sit down and think that this is a feature, which, if you don't use, the old behaviour of the Clip is totally preserved. diff --git a/WPrefs.app/po/Makefile.in b/WPrefs.app/po/Makefile.in index a77e03e7..fe1cb4ba 100644 --- a/WPrefs.app/po/Makefile.in +++ b/WPrefs.app/po/Makefile.in @@ -98,7 +98,7 @@ nlsdir = $(NLSDIR) CLEANFILES = $(CATALOGS) -EXTRA_DIST = pt.po hr.po fr.po ko.po cs.po ja.po zh_TW.Big5.po es.po zh_CN.po fi.po it.po +EXTRA_DIST = pt.po hr.po fr.po ko.po cs.po ja.po zh_TW.Big5.po es.po zh_CN.po fi.po it.po ru.po POTFILES = $(top_builddir)/WPrefs.app/main.c $(top_builddir)/WPrefs.app/WPrefs.c $(top_builddir)/WPrefs.app/Appearance.c $(top_builddir)/WPrefs.app/Configurations.c $(top_builddir)/WPrefs.app/Expert.c $(top_builddir)/WPrefs.app/Focus.c $(top_builddir)/WPrefs.app/Icons.c $(top_builddir)/WPrefs.app/KeyboardSettings.c $(top_builddir)/WPrefs.app/KeyboardShortcuts.c $(top_builddir)/WPrefs.app/Menu.c $(top_builddir)/WPrefs.app/MenuPreferences.c $(top_builddir)/WPrefs.app/MouseSettings.c $(top_builddir)/WPrefs.app/NoMenuAlert.c $(top_builddir)/WPrefs.app/Paths.c $(top_builddir)/WPrefs.app/Preferences.c $(top_builddir)/WPrefs.app/Text.c $(top_builddir)/WPrefs.app/TexturePanel.c $(top_builddir)/WPrefs.app/Themes.c $(top_builddir)/WPrefs.app/WindowHandling.c $(top_builddir)/WPrefs.app/Workspace.c $(top_builddir)/WPrefs.app/double.c $(top_builddir)/WPrefs.app/editmenu.c $(top_builddir)/WPrefs.app/MenuGuru.c $(top_builddir)/WPrefs.app/xmodifier.c diff --git a/configure b/configure index 0a6cca4d..d39b011c 100755 --- a/configure +++ b/configure @@ -3147,7 +3147,7 @@ fi supported_locales="cs de es fr gl it ja ko nl no pt ru se tr fi hr el pl ro da zh_TW.Big5 zh_CN sk" -supported_wprefs_locales="pt hr fr ko ja cs zh_TW.Big5 es zh_CN fi it" +supported_wprefs_locales="pt hr fr ko ja cs zh_TW.Big5 es zh_CN fi it ru" for lang in $LINGUAS; do ok=0 diff --git a/src/dock.c b/src/dock.c index 622dbb18..e7b93ea7 100644 --- a/src/dock.c +++ b/src/dock.c @@ -1162,9 +1162,10 @@ dockMenuCreate(WScreen *scr, int type) free(entry->text); entry->text = _("Rename Workspace"); - entry = wMenuAddCallback(menu, _("Select Icon"), selectCallback, NULL); - free(entry->text); - entry->text = _("Select Icon"); + entry = wMenuAddCallback(menu, _("Selected"), selectCallback, NULL); + entry->flags.indicator = 1; + entry->flags.indicator_on = 1; + entry->flags.indicator_type = MI_CHECK; entry = wMenuAddCallback(menu, _("Select All Icons"), selectIconsCallback, NULL); @@ -3379,32 +3380,26 @@ openDockMenu(WDock *dock, WAppIcon *aicon, XEvent *event) if (aicon == scr->clip_icon) { entry->callback = renameCallback; entry->clientdata = dock; - //entry->flags.indicator = 0; + entry->flags.indicator = 0; entry->text = _("Rename Workspace"); } else { entry->callback = omnipresentCallback; entry->clientdata = aicon; - //entry->flags.indicator = 1; - //entry->flags.indicator_on = aicon->omnipresent; - //entry->flags.indicator_type = MI_CHECK; - //entry->text = _("Omnipresent"); if (n_selected > 0) { + entry->flags.indicator = 0; entry->text = _("Toggle Omnipresent"); } else { - if (aicon->omnipresent) - entry->text = _("Unset Omnipresent"); - else - entry->text = _("Set Omnipresent"); + entry->flags.indicator = 1; + entry->flags.indicator_on = aicon->omnipresent; + entry->flags.indicator_type = MI_CHECK; + entry->text = _("Omnipresent"); } } /* select/unselect icon */ entry = dock->menu->entries[++index]; entry->clientdata = aicon; - if (aicon->icon->selected) - entry->text = _("Unselect Icon"); - else - entry->text = _("Select Icon"); + entry->flags.indicator_on = aicon->icon->selected; wMenuSetEnabled(dock->menu, index, aicon!=scr->clip_icon); /* select/unselect all icons */