Guest User

Untitled

a guest
Jun 22nd, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.11 KB | None | 0 0
  1. Index: SumatraPDF.cpp
  2. ===================================================================
  3. --- SumatraPDF.cpp (revision 1127)
  4. +++ SumatraPDF.cpp (working copy)
  5. @@ -4708,6 +4708,12 @@
  6. if (!WindowInfo_PdfLoaded(win))
  7. return;
  8.  
  9. + // Don't show a dialog if we don't have to - use the Toolbar instead
  10. + if (gGlobalPrefs.m_showToolbar) {
  11. + win->PageStart();
  12. + return;
  13. + }
  14. +
  15. int newPageNo = Dialog_GoToPage(win);
  16. if (win->dm->validPageNo(newPageNo))
  17. win->dm->goToPage(newPageNo, 0);
  18. @@ -5734,6 +5740,13 @@
  19. }
  20. }
  21.  
  22. +void WindowInfo::PageStart()
  23. +{
  24. + hwndTracker = NULL;
  25. + SendMessage(hwndPageBox, EM_SETSEL, 0, -1);
  26. + SetFocus(hwndPageBox);
  27. +}
  28. +
  29. void WindowInfo::TrackMouse(HWND tracker)
  30. {
  31. if (!tracker)
  32. Index: SumatraPDF.h
  33. ===================================================================
  34. --- SumatraPDF.h (revision 1127)
  35. +++ SumatraPDF.h (working copy)
  36. @@ -233,6 +233,7 @@
  37. void TrackMouse(HWND hwnd=NULL);
  38. void FindStart();
  39. virtual void FindUpdateStatus(int count, int total);
  40. + void PageStart();
  41.  
  42. };
Add Comment
Please, Sign In to add comment