mirror of
https://gitlab.com/manzerbredes/ochess.git
synced 2025-06-14 01:47:40 +00:00
Improve live engine dialog
This commit is contained in:
parent
5f209bd1d5
commit
0e18d4ac87
6 changed files with 23 additions and 7 deletions
|
@ -1,4 +1,5 @@
|
|||
#include "EditorPanel.hpp"
|
||||
#include "LiveEngineDialog.hpp"
|
||||
|
||||
wxDEFINE_EVENT(GOTO_MOVE_EVENT, wxCommandEvent);
|
||||
wxDEFINE_EVENT(DELETE_MOVE_EVENT, wxCommandEvent);
|
||||
|
@ -16,6 +17,8 @@ EditorPanel::EditorPanel(wxFrame *parent, Game *game)
|
|||
tagTextCtrl->SetHint("Tag");
|
||||
valueTextCtrl->SetHint("Value");
|
||||
|
||||
LiveEngineDialog *diag=new LiveEngineDialog(this);
|
||||
diag->Show();
|
||||
RefreshTagsList();
|
||||
|
||||
// Bind events
|
||||
|
|
7
src/game_tab/editor/LiveEngineDialog.cpp
Normal file
7
src/game_tab/editor/LiveEngineDialog.cpp
Normal file
|
@ -0,0 +1,7 @@
|
|||
#include "LiveEngineDialog.hpp"
|
||||
|
||||
LiveEngineDialog::LiveEngineDialog(wxWindow *parent)
|
||||
: LiveEngineDialogFB(parent) {
|
||||
lines_list->InsertColumn(0, "#");
|
||||
lines_list->InsertColumn(1, "Moves",wxLIST_FORMAT_LEFT, 500);
|
||||
}
|
7
src/game_tab/editor/LiveEngineDialog.hpp
Normal file
7
src/game_tab/editor/LiveEngineDialog.hpp
Normal file
|
@ -0,0 +1,7 @@
|
|||
#include "ochess.hpp"
|
||||
#include "LiveEngineDialogFB.h"
|
||||
|
||||
class LiveEngineDialog : public LiveEngineDialogFB {
|
||||
public:
|
||||
LiveEngineDialog(wxWindow *parent);
|
||||
};
|
|
@ -30,8 +30,8 @@ LiveEngineDialogFB::LiveEngineDialogFB( wxWindow* parent, wxWindowID id, const w
|
|||
|
||||
main_sizer->Add( current_engine_sizer, 0, wxEXPAND, 5 );
|
||||
|
||||
lines_list = new wxListBox( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0, NULL, 0 );
|
||||
main_sizer->Add( lines_list, 1, wxALL|wxEXPAND, 5 );
|
||||
lines_list = new wxListCtrl( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLC_REPORT );
|
||||
main_sizer->Add( lines_list, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
this->SetSizer( main_sizer );
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
#include <wx/colour.h>
|
||||
#include <wx/settings.h>
|
||||
#include <wx/sizer.h>
|
||||
#include <wx/listbox.h>
|
||||
#include <wx/listctrl.h>
|
||||
#include <wx/dialog.h>
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
@ -32,7 +32,7 @@ class LiveEngineDialogFB : public wxDialog
|
|||
protected:
|
||||
wxStaticText* current_engine_label;
|
||||
wxStaticText* current_engine;
|
||||
wxListBox* lines_list;
|
||||
wxListCtrl* lines_list;
|
||||
|
||||
public:
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue