[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[paragui-cvs] CVS: paragui/src/widgets pgthemewidget.cpp,1.3,1.3.2.1 pgw
From: |
Alexander Pipelka <address@hidden> |
Subject: |
[paragui-cvs] CVS: paragui/src/widgets pgthemewidget.cpp,1.3,1.3.2.1 pgwidget.cpp,1.3,1.3.2.1 |
Date: |
Tue, 16 Apr 2002 14:06:44 -0400 |
Update of /cvsroot/paragui/paragui/src/widgets
In directory subversions:/tmp/cvs-serv11803/src/widgets
Modified Files:
Tag: devel-1-1
pgthemewidget.cpp pgwidget.cpp
Log Message:
- opened "devel-1-1" (unstable) branch
- new PG_RectList implementation (uses the iterator as index)
- removed obsolete glmode flags
- removed obsolete bulkmode flags from PG_Application
- fixed ProcessEvent function (different signatures of the virtual function)
Index: pgthemewidget.cpp
===================================================================
RCS file: /cvsroot/paragui/paragui/src/widgets/pgthemewidget.cpp,v
retrieving revision 1.3
retrieving revision 1.3.2.1
diff -C2 -r1.3 -r1.3.2.1
Index: pgwidget.cpp
===================================================================
RCS file: /cvsroot/paragui/paragui/src/widgets/pgwidget.cpp,v
retrieving revision 1.3
retrieving revision 1.3.2.1
diff -C2 -r1.3 -r1.3.2.1
*** pgwidget.cpp 15 Apr 2002 13:35:36 -0000 1.3
--- pgwidget.cpp 16 Apr 2002 18:06:41 -0000 1.3.2.1
***************
*** 453,457 ****
}
! if(!PG_Application::GetBulkMode()) {
UpdateRect(vertical);
UpdateRect(horizontal);
--- 453,457 ----
}
! if(!bBulkUpdate) {
UpdateRect(vertical);
UpdateRect(horizontal);
***************
*** 718,722 ****
RestoreBackground();
! if(!PG_Application::GetBulkMode()) {
UpdateRect(my_internaldata->rectClip);
}
--- 718,722 ----
RestoreBackground();
! if(!bBulkUpdate) {
UpdateRect(my_internaldata->rectClip);
}
***************
*** 724,728 ****
SDL_SetClipRect(my_srfScreen, NULL);
! if(!PG_Application::GetBulkMode()) {
PG_Application::LockScreen();
SDL_UpdateRects(my_srfScreen, 1, &my_internaldata->rectClip);
--- 724,728 ----
SDL_SetClipRect(my_srfScreen, NULL);
! if(!bBulkUpdate) {
PG_Application::LockScreen();
SDL_UpdateRects(my_srfScreen, 1, &my_internaldata->rectClip);
***************
*** 783,787 ****
// restore the background
! if(restore) {
RestoreBackground(&my_internaldata->rectClip);
}
--- 783,787 ----
// restore the background
! if(restore && !bBulkUpdate) {
RestoreBackground(&my_internaldata->rectClip);
}
***************
*** 810,814 ****
static PG_Rect dst;
! if(PG_Application::GetBulkMode()) {
return;
}
--- 810,814 ----
static PG_Rect dst;
! if(bBulkUpdate) {
return;
}
***************
*** 841,845 ****
}
! int index = 0;
// check if other children of my parent overlap myself
--- 841,845 ----
}
! PG_RectList::iterator index;
// check if other children of my parent overlap myself
***************
*** 848,854 ****
if(children) {
index = children->FindIndexOf(this);
! if(index != -1) {
SDL_SetClipRect(my_srfScreen,
&my_internaldata->rectClip);
!
children->Intersect(&my_internaldata->rectClip, index+1,
-1).Blit(my_internaldata->rectClip);
}
}
--- 848,854 ----
if(children) {
index = children->FindIndexOf(this);
! if(index != children->end()) {
SDL_SetClipRect(my_srfScreen,
&my_internaldata->rectClip);
!
children->Intersect(&my_internaldata->rectClip,
++index).Blit(my_internaldata->rectClip);
}
}
***************
*** 861,867 ****
index = widgetList.FindIndexOf(obj);
! if(index != -1) {
SDL_SetClipRect(my_srfScreen,
&my_internaldata->rectClip);
! widgetList.Intersect(&my_internaldata->rectClip,
index+1, -1).Blit(my_internaldata->rectClip);
}
--- 861,867 ----
index = widgetList.FindIndexOf(obj);
! if(index != widgetList.end()) {
SDL_SetClipRect(my_srfScreen,
&my_internaldata->rectClip);
! widgetList.Intersect(&my_internaldata->rectClip,
++index).Blit(my_internaldata->rectClip);
}
***************
*** 929,934 ****
void PG_Widget::HideAll() {
! for(Uint16 i=0; i<widgetList.size(); i++) {
! widgetList[i]->Hide();
}
}
--- 929,934 ----
void PG_Widget::HideAll() {
! for(PG_RectList::iterator i = widgetList.begin(); i !=
widgetList.end(); i++) {
! (*i)->Hide();
}
}
***************
*** 937,947 ****
bBulkUpdate = true;
! for(Uint16 i=0; i<widgetList.size(); i++) {
! if(widgetList[i]->IsVisible()) {
! widgetList[i]->Update();
}
}
! bBulkUpdate = false;
}
--- 937,947 ----
bBulkUpdate = true;
! for(PG_RectList::iterator i = widgetList.begin(); i !=
widgetList.end(); i++) {
! if((*i)->IsVisible()) {
! (*i)->Update();
}
}
! // bBulkUpdate = false;
}
***************
*** 949,954 ****
bBulkUpdate = true;
widgetList.Blit();
! PG_Application::DrawCursor();
! bBulkUpdate = false;
}
--- 949,954 ----
bBulkUpdate = true;
widgetList.Blit();
! PG_Application::DrawCursor(false);
! // bBulkUpdate = false;
}
***************
*** 1105,1109 ****
}
! if(PG_Application::GetBulkMode()) {
return false;
}
--- 1105,1109 ----
}
! if(bBulkUpdate) {
return false;
}
***************
*** 1116,1124 ****
PG_Application::RedrawBackground(*clip);
! int index = widgetList.FindIndexOf(this);
! if(index != -1) {
SDL_SetClipRect(my_srfScreen, clip);
! widgetList.Intersect(clip, 0, index).Blit(*clip);
}
return true;
--- 1116,1124 ----
PG_Application::RedrawBackground(*clip);
! PG_RectList::iterator index = widgetList.FindIndexOf(this);
! if(index != widgetList.end()) {
SDL_SetClipRect(my_srfScreen, clip);
! widgetList.Intersect(clip, widgetList.begin(),
index).Blit(*clip);
}
return true;
***************
*** 1166,1170 ****
void PG_Widget::UpdateRect(const PG_Rect& r) {
! if(PG_Application::GetBulkMode()) {
return;
}
--- 1166,1170 ----
void PG_Widget::UpdateRect(const PG_Rect& r) {
! if(bBulkUpdate) {
return;
}
***************
*** 1201,1205 ****
}
! return (list->FindIndexOf(w1) > list->FindIndexOf(w2));
}
--- 1201,1214 ----
}
! bool found = false;
! for(PG_RectList::iterator i = list->FindIndexOf(w1); i != list->end();
i++) {
! if((*i) == w2) {
! found = true;
! break;
! }
! }
!
! return !found;
! //return (list->FindIndexOf(w1) > list->FindIndexOf(w2));
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [paragui-cvs] CVS: paragui/src/widgets pgthemewidget.cpp,1.3,1.3.2.1 pgwidget.cpp,1.3,1.3.2.1,
Alexander Pipelka <address@hidden> <=
- Prev by Date:
[paragui-cvs] CVS: paragui/src/core pgapplication.cpp,1.1,1.1.2.1 pgfilearchive.cpp,1.1,1.1.2.1 pgmessageobject.cpp,1.1,1.1.2.1 pgrectlist.cpp,1.1,1.1.2.1
- Next by Date:
[paragui-cvs] CVS: paragui/include pgbutton.h,1.3,1.3.2.1
- Previous by thread:
[paragui-cvs] CVS: paragui/src/core pgapplication.cpp,1.1,1.1.2.1 pgfilearchive.cpp,1.1,1.1.2.1 pgmessageobject.cpp,1.1,1.1.2.1 pgrectlist.cpp,1.1,1.1.2.1
- Next by thread:
[paragui-cvs] CVS: paragui/include pgbutton.h,1.3,1.3.2.1
- Index(es):