improve resizing

This commit is contained in:
Andrzej Rybczak
2009-02-16 00:37:03 +01:00
parent f9cdfa5d2b
commit ba6c2db0b1
16 changed files with 82 additions and 78 deletions

View File

@@ -34,10 +34,6 @@ using namespace Global;
using namespace MPD;
using std::string;
//Window *Global::wPlaylistEditorActiveCol;
//Menu<string> *Global::List;
//Menu<Song> *Global::Content;
PlaylistEditor *myPlaylistEditor = new PlaylistEditor;
size_t PlaylistEditor::LeftColumnWidth;
@@ -76,6 +72,8 @@ void PlaylistEditor::Resize()
Content->Resize(RightColumnWidth, main_height);
Content->MoveTo(RightColumnStartX, main_start_y);
hasToBeResized = 0;
}
std::string PlaylistEditor::Title()
@@ -95,6 +93,9 @@ void PlaylistEditor::SwitchTo()
if (myScreen == this)
return;
if (hasToBeResized)
Resize();
CLEAR_FIND_HISTORY;
myScreen = this;
myPlaylist->Main()->Hide(); // hack, should be myScreen, but it doesn't always have 100% width