From 4f72ab3712ca53c14c35052af41fa4097e4e3d3f Mon Sep 17 00:00:00 2001 From: george82 Date: Sun, 10 Sep 2006 05:13:45 +0000 Subject: [PATCH] Implemented Actual Size and Auto Size the vncviewer toolbar buttons. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@655 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- win/vncviewer/CConn.cxx | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/win/vncviewer/CConn.cxx b/win/vncviewer/CConn.cxx index 4a5f32da..b9ea5ad7 100644 --- a/win/vncviewer/CConn.cxx +++ b/win/vncviewer/CConn.cxx @@ -53,6 +53,10 @@ const int IDM_CTRL_KEY = ID_CTRL_KEY; const int IDM_ALT_KEY = ID_ALT_KEY; const int IDM_FILE_TRANSFER = ID_FILE_TRANSFER; const int IDM_CONN_SAVE_AS = ID_CONN_SAVE_AS; +const int IDM_ZOOM_IN = ID_ZOOM_IN; +const int IDM_ZOOM_OUT = ID_ZOOM_OUT; +const int IDM_ACTUAL_SIZE = ID_ACTUAL_SIZE; +const int IDM_AUTO_SIZE = ID_AUTO_SIZE; static IntParameter debugDelay("DebugDelay","Milliseconds to display inverted " @@ -182,6 +186,23 @@ CConn::sysCommand(WPARAM wParam, LPARAM lParam) { options.fullScreen = !window->isFullscreen(); window->setFullscreen(options.fullScreen); return true; + case IDM_ZOOM_IN: + return true; + case IDM_ZOOM_OUT: + return true; + case IDM_ACTUAL_SIZE: + if (options.autoScaling) { + options.autoScaling = false; + window->setAutoScaling(false); + } + options.scaling = false; + options.scale = 100; + window->setDesktopScale(100); + return true; + case IDM_AUTO_SIZE: + options.autoScaling = true; + window->setAutoScaling(true); + return true; case IDM_SHOW_TOOLBAR: options.showToolbar = !window->isToolbarEnabled(); window->setShowToolbar(options.showToolbar); -- 2.39.5