* BUG: Fix a Slider warning when setting the MinValue or MaxValue property.

[GB.GTK3]
* BUG: Painting a DrawingArea is done with the correct origin now.


git-svn-id: svn://localhost/gambas/trunk@6163 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
Benoît Minisini 2014-02-16 23:12:50 +00:00
parent 513aac869e
commit 34cd87e0d9
2 changed files with 9 additions and 4 deletions

View File

@ -260,6 +260,11 @@ static int Begin(GB_PAINT *d)
EXTRA(d)->context = ((CDRAWINGAREA *)device)->context;
cairo_reference(CONTEXT(d));
GtkAllocation a;
gtk_widget_get_allocation(wid->border, &a);
dx = a.x;
dy = a.y;
}
d->resolutionX = gDesktop::resolution(); //device->physicalDpiX();

View File

@ -195,8 +195,8 @@ int gSlider::value()
void gSlider::setMax(int vl)
{
_max = vl;
if (_min > _max)
_min = _max;
if (_min >= _max)
_min = _max - 1;
init();
updateMark();
}
@ -204,8 +204,8 @@ void gSlider::setMax(int vl)
void gSlider::setMin(int vl)
{
_min = vl;
if (_min > _max)
_max = _min;
if (_min >= _max)
_max = _min + 1;
init();
updateMark();
}