diff options
author | Bastian Wissler | 2008-10-15 10:54:57 +0200 |
---|---|---|
committer | Bastian Wissler | 2008-10-15 10:54:57 +0200 |
commit | 75e10a2dae20dbf7ef7629d7d658e4114e39ded6 (patch) | |
tree | 7ebf6433edd4886a95d2b9e835108fa2ca421c63 | |
parent | source of vmchooser updated to fix a bug when starting an image (diff) | |
download | vmchooser-75e10a2dae20dbf7ef7629d7d658e4114e39ded6.tar.gz vmchooser-75e10a2dae20dbf7ef7629d7d658e4114e39ded6.tar.xz vmchooser-75e10a2dae20dbf7ef7629d7d658e4114e39ded6.zip |
vmchooser fixes: * group item is now considered - version 0.0.3 / xserver: * changes to suse-gfx-install.sh: added better SuSE version
git-svn-id: http://svn.openslx.org/svn/openslx/openslx-src-tools/vmchooser/trunk@2311 95ad53e4-c205-0410-b2fa-d234c58c8868
-rw-r--r-- | vmchooser/SWindow.cxx | 21 | ||||
-rw-r--r-- | vmchooser/main.cxx | 2 |
2 files changed, 14 insertions, 9 deletions
diff --git a/vmchooser/SWindow.cxx b/vmchooser/SWindow.cxx index 1763ddb..9906fd8 100644 --- a/vmchooser/SWindow.cxx +++ b/vmchooser/SWindow.cxx @@ -21,12 +21,16 @@ using namespace std; * ---------------------------------------------------- * if you want to use default sizes, call first ctor ********************************************************/ -SWindow::SWindow(int w, int h, char* p): - fltk::Window(fltk::USEDEFAULT,fltk::USEDEFAULT,w,h,p, true), - go(w/3 + 10, h-40, (2*w)/3 - 20 , 30, "START"), - exit_btn(10, h-40, w/3 -10, 30, "EXIT"), - sel(10,10, w-20, h-50) +SWindow::SWindow(int w, int h, char* p) +: fltk::Window(w,h,p), + go(w/3 + 10, h-40, (2*w)/3 - 20 , 30, "START"), + exit_btn(10, h-40, w/3 -10, 30, "EXIT"), + sel(10,10, w-20, h-50) { + begin(); + add_resizable(sel); + add(exit_btn); + add(go); width = w; height = h; @@ -41,7 +45,7 @@ SWindow::SWindow(int w, int h, char* p): sel.indented(1); - Font* f1 = font("sans bold"); + Font* f1 = font("sans"); //Font* f1bold = f1->bold(); btn_style->textsize(16); @@ -60,6 +64,7 @@ SWindow::SWindow(int w, int h, char* p): sel.column_widths(widths); end(); + sel.take_focus(); }; @@ -90,6 +95,8 @@ void SWindow::cb_return() *******************************************************/ void SWindow::cb_select() { + oldcurr = curr; + curr = (Item*) sel.item(); if(!sel.item()) return; //cout << "cb_select called with" << sel.item() << endl; sel.select_only_this(); @@ -98,8 +105,6 @@ void SWindow::cb_select() sel.set_item_opened(true); return; } - oldcurr = curr; - curr = (Item*) sel.item(); if( curr == oldcurr ) { // start image if it has data associated diff --git a/vmchooser/main.cxx b/vmchooser/main.cxx index 7f15792..982b3e4 100644 --- a/vmchooser/main.cxx +++ b/vmchooser/main.cxx @@ -111,7 +111,7 @@ int main(int argc, char** argv) { delete opt; // just print out version information - helps testing - cout << "virtual machine chooser 0.0.2"<< endl; + cout << "virtual machine chooser 0.0.3"<< endl; if(version) { exit(1); } |