* Double click now toggles full screen, as in the MediaPlayer.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41069 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler 2011-03-21 15:32:23 +00:00
parent bfb8680ff1
commit cf9f46bc60
3 changed files with 11 additions and 3 deletions

View File

@ -1071,9 +1071,17 @@ ShowImageView::MouseDown(BPoint position)
MakeFocus(true);
BPoint point = ViewToImage(position);
int32 clickCount = 0;
uint32 buttons = 0;
if (Window() != NULL && Window()->CurrentMessage() != NULL)
if (Window() != NULL && Window()->CurrentMessage() != NULL) {
clickCount = Window()->CurrentMessage()->FindInt32("clicks");
buttons = Window()->CurrentMessage()->FindInt32("buttons");
}
if (buttons == B_PRIMARY_MOUSE_BUTTON && clickCount == 2) {
Window()->PostMessage(MSG_FULL_SCREEN);
return;
}
if (fHasSelection && fSelectionBox.Bounds().Contains(point)
&& (buttons

View File

@ -88,7 +88,6 @@ enum {
MSG_FLIP_LEFT_TO_RIGHT = 'mFLR',
MSG_FLIP_TOP_TO_BOTTOM = 'mFTB',
MSG_SLIDE_SHOW_DELAY = 'mSSD',
MSG_FULL_SCREEN = 'mFSC',
MSG_SHOW_CAPTION = 'mSCP',
MSG_PAGE_SETUP = 'mPSU',
MSG_PREPARE_PRINT = 'mPPT',

View File

@ -41,6 +41,7 @@ enum {
kMsgDeleteCurrentFile = 'mDcF',
MSG_SLIDE_SHOW = 'mSSW',
kMsgStopSlideShow = 'msss',
MSG_FULL_SCREEN = 'mFSC',
MSG_EXIT_FULL_SCREEN = 'mEFS',
MSG_WINDOW_HAS_QUIT = 'wndq'
};