Make Fl_Table::get_selection() 'const' (#1305)
This commit is contained in:
parent
c223f99f71
commit
9b9426bf6e
@ -3,7 +3,7 @@
|
||||
//
|
||||
// Copyright 2002 by Greg Ercolano.
|
||||
// Copyright (c) 2004 O'ksi'D
|
||||
// Copyright 2023 by Bill Spitzak and others.
|
||||
// Copyright 2023-2025 by Bill Spitzak and others.
|
||||
//
|
||||
// This library is free software. Distribution and use rights are outlined in
|
||||
// the file "COPYING" which should have been included with this file. If this
|
||||
@ -736,11 +736,15 @@ public:
|
||||
return(row_position());
|
||||
}
|
||||
int is_selected(int r, int c); // selected cell
|
||||
#if FL_ABI_VERSION >= 10405 // Issue #1305
|
||||
void get_selection(int &row_top, int &col_left, int &row_bot, int &col_right) const;
|
||||
#else
|
||||
void get_selection(int &row_top, int &col_left, int &row_bot, int &col_right);
|
||||
#endif
|
||||
void set_selection(int row_top, int col_left, int row_bot, int col_right);
|
||||
int move_cursor(int R, int C, int shiftselect);
|
||||
int move_cursor(int R, int C);
|
||||
void resize(int X, int Y, int W, int H) FL_OVERRIDE; // fltk resize() FL_OVERRIDE
|
||||
void resize(int X, int Y, int W, int H) FL_OVERRIDE; // fltk resize() override
|
||||
|
||||
// This crashes sortapp() during init.
|
||||
// void box(Fl_Boxtype val) {
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
//
|
||||
// Copyright 2002 by Greg Ercolano.
|
||||
// Copyright (c) 2004 O'ksi'D
|
||||
// Copyright 2023 by Bill Spitzak and others.
|
||||
// Copyright 2023-2025 by Bill Spitzak and others.
|
||||
//
|
||||
// This library is free software. Distribution and use rights are outlined in
|
||||
// the file "COPYING" which should have been included with this file. If this
|
||||
@ -1246,7 +1246,11 @@ int Fl_Table::is_selected(int r, int c) {
|
||||
\param[in] row_bot Returns the bottom row of selection area
|
||||
\param[in] col_right Returns the right column of selection area
|
||||
*/
|
||||
#if FL_ABI_VERSION >= 10405 // Issue #1305
|
||||
void Fl_Table::get_selection(int& row_top, int& col_left, int& row_bot, int& col_right) const {
|
||||
#else
|
||||
void Fl_Table::get_selection(int& row_top, int& col_left, int& row_bot, int& col_right) {
|
||||
#endif
|
||||
if (select_col > current_col) {
|
||||
col_left = current_col;
|
||||
col_right = select_col;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user