summaryrefslogtreecommitdiff
path: root/src/Fl_Gl_Window.cxx
diff options
context:
space:
mode:
authorBill Spitzak <spitzak@gmail.com>2000-03-05 06:51:07 +0000
committerBill Spitzak <spitzak@gmail.com>2000-03-05 06:51:07 +0000
commita32453e68093718f88cf6f17a165e4b8fe2a784f (patch)
treeba3a8ab32300090abf1807610a7a7c6c3c11d7f0 /src/Fl_Gl_Window.cxx
parentd6caf3aff8f9be57e15491134e4f6fb6941c2a17 (diff)
Moved FL_LEFT_MOUSE, FL_MIDDLE_MOUSE, and FL_RIGHT_MOUSE from forms.h to
Enumerations.H so they are available to any fltk programs. More fixes to the fake-overlay code in Fl_Gl_Window (it did not work on Win32 when there were 2 different-sized windows) Fix to Fl_compose to not quote the Delete key fixed to allow the right- control key to still be the compose prefix and to allow it to quote control characters. OSF1 used the same parameters for scandir as SGI and unlike Linux and apparently most other Unix's fl_ask, message, etc windows are resizable, which is useful if you use them to display arbitrary output from a program. On Win32 non_modal (but not modal) windows have close and size boxes, as per popular demand at Digital Domain. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@1028 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Gl_Window.cxx')
-rw-r--r--src/Fl_Gl_Window.cxx10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/Fl_Gl_Window.cxx b/src/Fl_Gl_Window.cxx
index ab3b0d4c1..efce8348d 100644
--- a/src/Fl_Gl_Window.cxx
+++ b/src/Fl_Gl_Window.cxx
@@ -1,5 +1,5 @@
//
-// "$Id: Fl_Gl_Window.cxx,v 1.12.2.6 2000/01/12 06:06:24 bill Exp $"
+// "$Id: Fl_Gl_Window.cxx,v 1.12.2.7 2000/03/05 06:51:05 bill Exp $"
//
// OpenGL window code for the Fast Light Tool Kit (FLTK).
//
@@ -205,7 +205,8 @@ void Fl_Gl_Window::flush() {
// we use a seperate context for the copy because rasterpos must be 0
// and depth test needs to be off:
- static GLXContext ortho_context;
+ static GLXContext ortho_context = 0;
+ static Fl_Gl_Window* ortho_window = 0;
int init = !ortho_context;
#ifdef WIN32
if (init) ortho_context = wglCreateContext(Fl_X::i(this)->private_dc);
@@ -214,7 +215,8 @@ void Fl_Gl_Window::flush() {
ortho_context = glXCreateContext(fl_display,g->vis,fl_first_context,1);
#endif
fl_set_gl_context(this, ortho_context);
- if (init || !save_valid) {
+ if (init || !save_valid || ortho_window != this) {
+ ortho_window = this;
glDisable(GL_DEPTH_TEST);
glReadBuffer(GL_BACK);
glDrawBuffer(GL_FRONT);
@@ -322,5 +324,5 @@ void Fl_Gl_Window::draw_overlay() {}
#endif
//
-// End of "$Id: Fl_Gl_Window.cxx,v 1.12.2.6 2000/01/12 06:06:24 bill Exp $".
+// End of "$Id: Fl_Gl_Window.cxx,v 1.12.2.7 2000/03/05 06:51:05 bill Exp $".
//