diff options
author | akir <akir> | 2004-09-29 09:58:11 (GMT) |
---|---|---|
committer | akir <akir> | 2004-09-29 09:58:11 (GMT) |
commit | c0777f792c3bb75e3f5fc048b531a06efe01f112 (patch) | |
tree | abb0ee3c94ca939466e135011d5f9206ddd241af /src | |
parent | c6208c29c345910a27b6774274a472d7cc738450 (diff) | |
download | fluxbox_paul-c0777f792c3bb75e3f5fc048b531a06efe01f112.zip fluxbox_paul-c0777f792c3bb75e3f5fc048b531a06efe01f112.tar.bz2 |
fix to make separators are not clickable/selectable
Diffstat (limited to 'src')
-rw-r--r-- | src/FbTk/Menu.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/FbTk/Menu.cc b/src/FbTk/Menu.cc index b1e186d..b2c8fc7 100644 --- a/src/FbTk/Menu.cc +++ b/src/FbTk/Menu.cc | |||
@@ -22,7 +22,7 @@ | |||
22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
23 | // DEALINGS IN THE SOFTWARE. | 23 | // DEALINGS IN THE SOFTWARE. |
24 | 24 | ||
25 | // $Id: Menu.cc,v 1.85 2004/09/12 14:56:19 rathnor Exp $ | 25 | // $Id: Menu.cc,v 1.86 2004/09/29 09:58:11 akir Exp $ |
26 | 26 | ||
27 | //use GNU extensions | 27 | //use GNU extensions |
28 | #ifndef _GNU_SOURCE | 28 | #ifndef _GNU_SOURCE |
@@ -1083,7 +1083,7 @@ void Menu::buttonPressEvent(XButtonEvent &be) { | |||
1083 | int sbl = (be.x / menu.item_w), i = (be.y / theme().itemHeight()); | 1083 | int sbl = (be.x / menu.item_w), i = (be.y / theme().itemHeight()); |
1084 | int w = (sbl * menu.persub) + i; | 1084 | int w = (sbl * menu.persub) + i; |
1085 | 1085 | ||
1086 | if (validIndex(w)) { | 1086 | if (validIndex(w) && isItemSelectable(static_cast<unsigned int>(w))) { |
1087 | which_press = i; | 1087 | which_press = i; |
1088 | which_sbl = sbl; | 1088 | which_sbl = sbl; |
1089 | 1089 | ||
@@ -1138,7 +1138,7 @@ void Menu::buttonReleaseEvent(XButtonEvent &re) { | |||
1138 | w = (sbl * menu.persub) + i, | 1138 | w = (sbl * menu.persub) + i, |
1139 | p = (which_sbl * menu.persub) + which_press; | 1139 | p = (which_sbl * menu.persub) + which_press; |
1140 | 1140 | ||
1141 | if (validIndex(w)) { | 1141 | if (validIndex(w) && isItemSelectable(static_cast<unsigned int>(w))) { |
1142 | if (p == w && isItemEnabled(w)) { | 1142 | if (p == w && isItemEnabled(w)) { |
1143 | if (re.x > ix && re.x < (signed) (ix + menu.item_w) && | 1143 | if (re.x > ix && re.x < (signed) (ix + menu.item_w) && |
1144 | re.y > iy && re.y < (signed) (iy + theme().itemHeight())) { | 1144 | re.y > iy && re.y < (signed) (iy + theme().itemHeight())) { |
@@ -1146,11 +1146,11 @@ void Menu::buttonReleaseEvent(XButtonEvent &re) { | |||
1146 | itemSelected(re.button, w); | 1146 | itemSelected(re.button, w); |
1147 | } | 1147 | } |
1148 | } | 1148 | } |
1149 | } | ||
1150 | 1149 | ||
1151 | drawItem(p, | 1150 | drawItem(p, |
1152 | true, // clear | 1151 | true, // clear |
1153 | true); // transparent | 1152 | true); // transparent |
1153 | } | ||
1154 | } | 1154 | } |
1155 | } | 1155 | } |
1156 | 1156 | ||