public void ZoomIn() { if (maxZoomOffset >= Constance.MaxZoomOffset) { ControlService.EnableZoom(MenuCommands.ZoomIn, false); ZoomInEnable = false; return; } ControlService.EnableZoom(MenuCommands.ZoomIn, true); ControlService.EnableZoom(MenuCommands.ZoomOut, true); ZoomInEnable = true; ZoomOutEnable = true; maxZoomOffset++; _Zoom++; ZoomInAndOut(_Zoom); }
public void ZoomOut() { if (_Zoom <= 1) { ControlService.EnableZoom(MenuCommands.ZoomOut, false); ZoomOutEnable = false; _Zoom = 1; return; } ControlService.EnableZoom(MenuCommands.ZoomIn, true); ControlService.EnableZoom(MenuCommands.ZoomOut, true); ZoomInEnable = true; ZoomOutEnable = true; maxZoomOffset--; _Zoom--; //_Zoom = _Zoom <= 1 ? 1 : _Zoom; ZoomInAndOut(_Zoom); }