------------------------------------------------------------------------------
| 166 | |
| 167 | //------------------------------------------------------------------------------ |
| 168 | bool GuiPopupTextListCtrlEx::onKeyDown(const GuiEvent &event) |
| 169 | { |
| 170 | //if the control is a dead end, don't process the input: |
| 171 | if ( !mVisible || !mActive || !mAwake ) |
| 172 | return false; |
| 173 | |
| 174 | //see if the key down is a <return> or not |
| 175 | if ( event.modifier == 0 ) |
| 176 | { |
| 177 | if ( event.keyCode == KEY_RETURN ) |
| 178 | { |
| 179 | mPopUpCtrl->closePopUp(); |
| 180 | return true; |
| 181 | } |
| 182 | else if ( event.keyCode == KEY_ESCAPE ) |
| 183 | { |
| 184 | mSelectedCell.set( -1, -1 ); |
| 185 | mPopUpCtrl->closePopUp(); |
| 186 | return true; |
| 187 | } |
| 188 | } |
| 189 | |
| 190 | //otherwise, pass the event to it's parent |
| 191 | return Parent::onKeyDown(event); |
| 192 | } |
| 193 | |
| 194 | void GuiPopupTextListCtrlEx::onMouseUp(const GuiEvent &event) |
| 195 | { |
nothing calls this directly
no test coverage detected