mirror of
https://gitlab.com/manzerbredes/cgeditor.git
synced 2025-04-05 17:46:28 +02:00
Cleaning code and update CMI
This commit is contained in:
parent
9a632b7d41
commit
298714449a
5 changed files with 9 additions and 7 deletions
|
@ -23,9 +23,12 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
void OnExit(wxCommandEvent &event) { Close(true); }
|
||||
void OnExit(wxCommandEvent &event) {
|
||||
(void)event; // Disable unused variable warning
|
||||
Close(true); }
|
||||
|
||||
void OnPaint(wxPaintEvent &event) {
|
||||
(void)event; // Disable unused variable warning
|
||||
wxPaintDC current_dc(this);
|
||||
dc = ¤t_dc;
|
||||
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 03ce4126cfa09ff0a55e70bdc44c1d5dd4035043
|
||||
Subproject commit 14ac3bba33a037e4b46b3f7ec9ba05760145f288
|
|
@ -12,6 +12,7 @@ protected:
|
|||
|
||||
public:
|
||||
Component(Status *s) : status(s){};
|
||||
virtual ~Component(){};
|
||||
std::vector<Element> GetElements() { return (this->elements); }
|
||||
virtual void Refresh() = 0;
|
||||
virtual void SyncCache() {};
|
||||
|
|
|
@ -181,7 +181,7 @@ std::uint32_t MoveTable::UpdateMoves(CMI::HalfMove *m, std::uint32_t line,
|
|||
|
||||
//---------- Variations ----------
|
||||
if (m->GetVariations().size() > 0) {
|
||||
line = DrawVariations(m, line, indent, move_bound, indent_black);
|
||||
line = DrawVariations(m, line, indent, move_bound);
|
||||
}
|
||||
|
||||
//---------- Mainline ----------
|
||||
|
@ -286,8 +286,7 @@ std::uint32_t MoveTable::DrawComment(CMI::HalfMove *m, std::uint32_t line,
|
|||
|
||||
std::uint32_t MoveTable::DrawVariations(CMI::HalfMove *m, std::uint32_t line,
|
||||
std::uint32_t indent,
|
||||
const Element &move_bound,
|
||||
const char &indent_black) {
|
||||
const Element &move_bound) {
|
||||
// Show three dots next to move if white turn
|
||||
if ((m->GetVariations().size() == 0) && !m->IsBlack()) {
|
||||
DRAW_DOTS(status->MarginBarWidth + status->MoveWidth * (indent + 1),
|
||||
|
|
|
@ -60,8 +60,7 @@ class MoveTable : public Component {
|
|||
std::uint32_t DrawComment(CMI::HalfMove *m, std::uint32_t line, std::uint32_t indent,
|
||||
const Element &move_bound, const char &indent_black);
|
||||
std::uint32_t DrawVariations(CMI::HalfMove *m, std::uint32_t line, std::uint32_t indent,
|
||||
const Element &move_bound,
|
||||
const char &indent_black);
|
||||
const Element &move_bound);
|
||||
public:
|
||||
MoveTable(Status *s);
|
||||
void Refresh();
|
||||
|
|
Loading…
Add table
Reference in a new issue