STR# #2973: applied patch str_2973_r9958_sun-fix-errors-5.patch verbatim.

src/Fl_Tree_Item.cxx -- solve: "Fl_Tree_Item.cxx",    line 614: Error: Initializing int& requires an lvalue.
    FL/Fl_Preferences.H  -- solve: "FL/Fl_Preferences.H", line 196: Error: Fl_Preferences::RootNode is not accessible from 0
    FL/Fl_Tree_Item.H    -- solve: "Fl_Tree_Item.cxx",    line 614: Error: Initializing int& requires an lvalue.
    test/unittests.cxx   -- solve: "unittests.cxx",        line 95: Error: The type "UnitTest*[]" is incomplete.
            


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9978 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Greg Ercolano 2013-09-16 20:25:14 +00:00
parent 578310dd0f
commit 67ed1a8da9
4 changed files with 10 additions and 6 deletions

View File

@ -185,6 +185,7 @@ private:
static char uuidBuffer[40];
static Fl_Preferences *runtimePrefs;
public: // older Sun compilers need this (public definition of the following classes)
class RootNode;
class FL_EXPORT Node { // a node contains a list to all its entries

View File

@ -61,7 +61,7 @@ class FL_EXPORT Fl_Tree_Item {
OPEN = 1<<0, ///> item is open
VISIBLE = 1<<1, ///> item is visible
ACTIVE = 1<<2, ///> item is active
SELECTED = 1<<3, ///> item is selected
SELECTED = 1<<3 ///> item is selected
};
#if FLTK_ABI_VERSION >= 10301
// NEW

View File

@ -611,9 +611,12 @@ void Fl_Tree_Item::draw(int X, int &Y, int W, Fl_Widget *tree,
// We don't care about items clipped off the viewport; they won't get mouse events.
//
int item_y_center = Y+(H/2);
int &icon_w = _collapse_xywh[2] = prefs.openicon()->w();
int &icon_x = _collapse_xywh[0] = X + (icon_w + prefs.connectorwidth())/2 - 3;
int &icon_y = _collapse_xywh[1] = item_y_center - (prefs.openicon()->h()/2);
_collapse_xywh[2] = prefs.openicon()->w();
int &icon_w = _collapse_xywh[2];
_collapse_xywh[0] = X + (icon_w + prefs.connectorwidth())/2 - 3;
int &icon_x = _collapse_xywh[0];
_collapse_xywh[1] = item_y_center - (prefs.openicon()->h()/2);
int &icon_y = _collapse_xywh[1];
_collapse_xywh[3] = prefs.openicon()->h();
// Horizontal connector values

View File

@ -88,11 +88,11 @@ private:
nTest++;
}
static int nTest;
static UnitTest *fTest[200];
static UnitTest *fTest[];
};
int UnitTest::nTest = 0;
UnitTest *UnitTest::fTest[];
UnitTest *UnitTest::fTest[200];
// The main window needs an additional drawing feature in order to support