-void OBActions::insertPress(const XButtonEvent &e)
-{
- ButtonPressAction *a = _posqueue[BUTTONS - 1];
- for (int i=BUTTONS-1; i>0;)
- _posqueue[i] = _posqueue[--i];
- _posqueue[0] = a;
- a->button = e.button;
- a->pos.setPoint(e.x, e.y);
-}
-
-void OBActions::removePress(const XButtonEvent &e)
-{
- ButtonPressAction *a = 0;
- for (int i=0; i<BUTTONS; ++i) {
- if (_posqueue[i]->button == e.button)
- a = _posqueue[i];
- if (a) // found one and removed it
- _posqueue[i] = _posqueue[i+1];
- }
- if (a) { // found one
- _posqueue[BUTTONS-1] = a;
- a->button = 0;
- }
-}
-