Commit 7a511336 authored by Davis King's avatar Davis King

Removed the confusing and unnecessary hidden bool argument to the style

drawing functions.

--HG--
extra : convert_revision : svn%3Afdd8eb12-d10e-0410-9acb-85c331704f74/trunk%402593
parent 07b0dae0
......@@ -896,7 +896,7 @@ namespace dlib
void draw (
const canvas& c
) const { style->draw_button(c,rect,hidden,enabled,*mfont,lastx,lasty,name_,is_depressed()); }
) const { style->draw_button(c,rect,enabled,*mfont,lastx,lasty,name_,is_depressed()); }
void on_button_up (
bool mouse_over
......@@ -1204,7 +1204,7 @@ namespace dlib
const canvas& c
) const
{
my_scroll_bar.style->draw_scroll_bar_background(c,rect,hidden,enabled,lastx,lasty,is_depressed());
my_scroll_bar.style->draw_scroll_bar_background(c,rect,enabled,lastx,lasty,is_depressed());
}
void on_button_down (
......@@ -1307,7 +1307,7 @@ namespace dlib
const canvas& c
) const
{
my_scroll_bar.style->draw_scroll_bar_slider(c,rect,hidden,enabled,lastx,lasty, is_being_dragged());
my_scroll_bar.style->draw_scroll_bar_slider(c,rect,enabled,lastx,lasty, is_being_dragged());
}
bool mouse_in_widget;
......
......@@ -17,7 +17,6 @@ namespace dlib
void button_style_default::draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -107,7 +106,6 @@ namespace dlib
void button_style_toolbar1::draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -206,7 +204,6 @@ namespace dlib
void button_style_toolbar_icon1::draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -405,7 +402,6 @@ namespace dlib
draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -426,7 +422,6 @@ namespace dlib
draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -447,7 +442,6 @@ namespace dlib
draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -468,7 +462,6 @@ namespace dlib
draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -490,7 +483,6 @@ namespace dlib
void toggle_button_style_default::draw_toggle_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -581,7 +573,6 @@ namespace dlib
void toggle_button_style_check_box::draw_toggle_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -674,7 +665,6 @@ namespace dlib
void toggle_button_style_radio_button::draw_toggle_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -850,7 +840,6 @@ namespace dlib
draw_scroll_bar_background (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const long lastx,
const long lasty,
......@@ -869,7 +858,6 @@ namespace dlib
draw_scroll_bar_slider (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const long lastx,
const long lasty,
......
......@@ -46,7 +46,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -66,7 +65,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -100,7 +98,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -149,7 +146,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -223,7 +219,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -246,7 +241,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -269,7 +263,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -292,7 +285,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -335,7 +327,6 @@ namespace dlib
virtual void draw_toggle_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -356,7 +347,6 @@ namespace dlib
virtual void draw_toggle_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -389,7 +379,6 @@ namespace dlib
virtual void draw_toggle_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -414,7 +403,6 @@ namespace dlib
virtual void draw_toggle_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -462,7 +450,6 @@ namespace dlib
virtual void draw_scroll_bar_background (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const long lastx,
const long lasty,
......@@ -472,7 +459,6 @@ namespace dlib
virtual void draw_scroll_bar_slider (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const long lastx,
const long lasty,
......@@ -514,7 +500,6 @@ namespace dlib
virtual void draw_scroll_bar_background (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const long lastx,
const long lasty,
......@@ -524,7 +509,6 @@ namespace dlib
virtual void draw_scroll_bar_slider (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const long lastx,
const long lasty,
......
......@@ -57,7 +57,6 @@ namespace dlib
virtual void draw_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -69,7 +68,7 @@ namespace dlib
requires
- the mutex drawable::m is locked
- c == the canvas to draw on
- rect, hidden, enabled, mfont, lastx, and lasty are the variables
- rect, enabled, mfont, lastx, and lasty are the variables
defined in the protected section of the drawable class.
- name == the name of the button to be drawn
- is_depressed == true if the button is to be drawn in a depressed state
......@@ -204,7 +203,6 @@ namespace dlib
virtual void draw_toggle_button (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const font& mfont,
const long lastx,
......@@ -217,7 +215,7 @@ namespace dlib
requires
- the mutex drawable::m is locked
- c == the canvas to draw on
- rect, hidden, enabled, mfont, lastx, and lasty are the variables
- rect, enabled, mfont, lastx, and lasty are the variables
defined in the protected section of the drawable class.
- name == the name of the button to be drawn
- is_depressed == true if the button is to be drawn in a depressed state
......@@ -335,7 +333,6 @@ namespace dlib
virtual void draw_scroll_bar_background (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const long lastx,
const long lasty,
......@@ -345,7 +342,7 @@ namespace dlib
requires
- the mutex drawable::m is locked
- c == the canvas to draw on
- rect, hidden, enabled, lastx, and lasty are the variables
- rect, enabled, lastx, and lasty are the variables
defined in the protected section of the drawable class.
- is_depressed == true if the background area of the scroll_bar is to
be drawn in a depressed state (because the user is clicking on it)
......@@ -357,7 +354,6 @@ namespace dlib
virtual void draw_scroll_bar_slider (
const canvas& c,
const rectangle& rect,
const bool hidden,
const bool enabled,
const long lastx,
const long lasty,
......@@ -367,7 +363,7 @@ namespace dlib
requires
- the mutex drawable::m is locked
- c == the canvas to draw on
- rect, hidden, enabled, lastx, and lasty are the variables
- rect, enabled, lastx, and lasty are the variables
defined in the protected section of the drawable class
- is_being_dragged == true if the user is dragging the slider
ensures
......
......@@ -274,7 +274,7 @@ namespace dlib
void draw (
const canvas& c
) const { style->draw_toggle_button(c,rect,hidden,enabled,*mfont,lastx,lasty,name_,is_depressed(),checked); }
) const { style->draw_toggle_button(c,rect,enabled,*mfont,lastx,lasty,name_,is_depressed(),checked); }
void on_button_up (
bool mouse_over
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment