37 scrollarea->ScrollBarsByViewPosition();
44 scrollarea->setScrollBarVisibility(!
PlayerLock);
49 #elif defined(USE_WIN32_WINDOWS)
51 void UpdateWindowLayout(HWND hwnd)
54 GetWindowRect(hwnd,&rect);
55 MoveWindow(hwnd,rect.left,rect.top,rect.right-rect.left-1,rect.bottom-rect.top,
true);
56 MoveWindow(hwnd,rect.left,rect.top,rect.right-rect.left,rect.bottom-rect.top,
true);
66 UpdateWindowLayout(
pWindow->hWindow);
74 UpdateWindowLayout(
pWindow->hWindow);
83 scroll.cbSize=
sizeof(SCROLLINFO);
86 GetScrollInfo(
pWindow->hWindow,SB_VERT,&scroll);
90 GetScrollInfo(
pWindow->hWindow,SB_HORZ,&scroll);
99 scroll.cbSize=
sizeof(SCROLLINFO);
101 scroll.fMask=SIF_ALL;
106 SetScrollInfo(
pWindow->hWindow,SB_VERT,&scroll,
true);
108 scroll.fMask=SIF_ALL;
113 SetScrollInfo(
pWindow->hWindow,SB_HORZ,&scroll,
true);
121 #ifdef WITH_QT_EDITOR
123 viewport_widget->update();
140 if (!result)
return result;
143 #ifndef WITH_QT_EDITOR
C4Application Application
const char * LoadResStr(const char *id)
int32_t ValidPlr(int32_t plr)
#define C4ViewportWindowStyle
StdStrBuf FormatString(const char *szFmt,...)
const char * GetSubkeyPath(const char *subkey)
bool Move(float iX, float iY, float zoom, DWORD dwKeyState)
int32_t GetHeight() const
const char * GetName() const
C4Player * Get(int iPlayer) const
bool ViewPositionByScrollBars()
bool UpdateOutputSize(int32_t new_width=0, int32_t new_height=0)
std::unique_ptr< C4ViewportWindow > pWindow
float WindowToGameX(int32_t win_x)
bool ScrollBarsByViewPosition()
float WindowToGameY(int32_t win_y)
bool CloseViewport(int32_t player_nr, bool silent)
virtual C4Window * Init(WindowKind windowKind, C4AbstractApp *pApp, const char *Title, const C4Rect *size)
void PerformUpdate() override
void EditCursorMove(int X, int Y, uint32_t)
virtual C4Window * Init(WindowKind windowKind, C4AbstractApp *pApp, const char *Title, const C4Rect *size)
bool RestorePosition(const char *szWindowName, const char *szSubKey, bool fHidden=false)