mirror of
https://github.com/fltk/fltk.git
synced 2026-06-01 06:14:28 +08:00
Make draw() protected (Fl_Tree + Fl_Table)
Widget draw() methods must be protected per FLTK convention.
This commit is contained in:
+6
-4
@@ -10,11 +10,11 @@
|
|||||||
// the file "COPYING" which should have been included with this file. If this
|
// the file "COPYING" which should have been included with this file. If this
|
||||||
// file is missing or damaged, see the license at:
|
// file is missing or damaged, see the license at:
|
||||||
//
|
//
|
||||||
// http://www.fltk.org/COPYING.php
|
// https://www.fltk.org/COPYING.php
|
||||||
//
|
//
|
||||||
// Please report all bugs and problems on the following page:
|
// Please report all bugs and problems on the following page:
|
||||||
//
|
//
|
||||||
// http://www.fltk.org/str.php
|
// https://www.fltk.org/str.php
|
||||||
//
|
//
|
||||||
|
|
||||||
#ifndef _FL_TABLE_H
|
#ifndef _FL_TABLE_H
|
||||||
@@ -423,7 +423,10 @@ protected:
|
|||||||
// Indicate partial redraw needed of some cells
|
// Indicate partial redraw needed of some cells
|
||||||
damage(FL_DAMAGE_CHILD);
|
damage(FL_DAMAGE_CHILD);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// draw() has to be protected per FLTK convention (was public in 1.3.x)
|
||||||
|
void draw();
|
||||||
|
|
||||||
public:
|
public:
|
||||||
Fl_Table(int X, int Y, int W, int H, const char *l=0);
|
Fl_Table(int X, int Y, int W, int H, const char *l=0);
|
||||||
~Fl_Table();
|
~Fl_Table();
|
||||||
@@ -758,7 +761,6 @@ public:
|
|||||||
int move_cursor(int R, int C, int shiftselect);
|
int move_cursor(int R, int C, int shiftselect);
|
||||||
int move_cursor(int R, int C);
|
int move_cursor(int R, int C);
|
||||||
void resize(int X, int Y, int W, int H); // fltk resize() override
|
void resize(int X, int Y, int W, int H); // fltk resize() override
|
||||||
void draw(void); // fltk draw() override
|
|
||||||
|
|
||||||
// This crashes sortapp() during init.
|
// This crashes sortapp() during init.
|
||||||
// void box(Fl_Boxtype val) {
|
// void box(Fl_Boxtype val) {
|
||||||
|
|||||||
+8
-5
@@ -24,11 +24,11 @@
|
|||||||
// the file "COPYING" which should have been included with this file. If this
|
// the file "COPYING" which should have been included with this file. If this
|
||||||
// file is missing or damaged, see the license at:
|
// file is missing or damaged, see the license at:
|
||||||
//
|
//
|
||||||
// http://www.fltk.org/COPYING.php
|
// https://www.fltk.org/COPYING.php
|
||||||
//
|
//
|
||||||
// Please report all bugs and problems on the following page:
|
// Please report all bugs and problems on the following page:
|
||||||
//
|
//
|
||||||
// http://www.fltk.org/str.php
|
// https://www.fltk.org/str.php
|
||||||
//
|
//
|
||||||
|
|
||||||
///
|
///
|
||||||
@@ -309,14 +309,17 @@ protected:
|
|||||||
int _tree_h;
|
int _tree_h;
|
||||||
void item_clicked(Fl_Tree_Item* val);
|
void item_clicked(Fl_Tree_Item* val);
|
||||||
void do_callback_for_item(Fl_Tree_Item* item, Fl_Tree_Reason reason);
|
void do_callback_for_item(Fl_Tree_Item* item, Fl_Tree_Reason reason);
|
||||||
// next_visible_item() and extend_selection() moved to 'public' in ABI 1.3.3
|
|
||||||
// undocmented draw_tree() dropped -- draw() does all the work now
|
// next_visible_item() and extend_selection() moved to 'public' in ABI 1.3.3
|
||||||
|
// undocmented draw_tree() dropped -- draw() does all the work now
|
||||||
|
|
||||||
|
// draw() has to be protected per FLTK convention (was public in 1.3.x)
|
||||||
|
void draw();
|
||||||
|
|
||||||
public:
|
public:
|
||||||
Fl_Tree(int X, int Y, int W, int H, const char *L=0);
|
Fl_Tree(int X, int Y, int W, int H, const char *L=0);
|
||||||
~Fl_Tree();
|
~Fl_Tree();
|
||||||
int handle(int e);
|
int handle(int e);
|
||||||
void draw();
|
|
||||||
void show_self();
|
void show_self();
|
||||||
void resize(int,int,int,int);
|
void resize(int,int,int,int);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user