summaryrefslogtreecommitdiff
path: root/src
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
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')
-rw-r--r--src/Fl_Gl_Window.cxx10
-rw-r--r--src/Fl_compose.cxx7
-rw-r--r--src/Fl_win32.cxx6
-rw-r--r--src/filename_list.cxx6
-rw-r--r--src/fl_ask.cxx10
5 files changed, 21 insertions, 18 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 $".
//
diff --git a/src/Fl_compose.cxx b/src/Fl_compose.cxx
index 44526ce8c..ada731a22 100644
--- a/src/Fl_compose.cxx
+++ b/src/Fl_compose.cxx
@@ -1,5 +1,5 @@
//
-// "$Id: Fl_compose.cxx,v 1.1.2.2 2000/02/29 21:54:55 mike Exp $"
+// "$Id: Fl_compose.cxx,v 1.1.2.3 2000/03/05 06:51:05 bill Exp $"
//
// Character compose processing for the Fast Light Tool Kit (FLTK).
//
@@ -64,9 +64,6 @@ int Fl::compose(int& del) {
del = 0;
char ascii = e_text[0];
- // The Delete and other special keys should not be composed...
- if (ascii < 32 || ascii == 127) return 0;
-
// Alt+letters are reserved for shortcuts. But alt+foreign letters
// has to be allowed, because some key layouts require alt to be held
// down in order to type them...
@@ -132,7 +129,7 @@ int Fl::compose(int& del) {
#endif
// Only insert non-control characters:
- if (e_length && (ascii&~31)) {compose_state = 0; return 1;}
+ if (e_length && (ascii & ~31 && ascii!=127)) {compose_state = 0; return 1;}
return 0;
}
diff --git a/src/Fl_win32.cxx b/src/Fl_win32.cxx
index 68f1b234e..f590c4fcc 100644
--- a/src/Fl_win32.cxx
+++ b/src/Fl_win32.cxx
@@ -1,5 +1,5 @@
//
-// "$Id: Fl_win32.cxx,v 1.33.2.21 2000/02/04 06:35:20 bill Exp $"
+// "$Id: Fl_win32.cxx,v 1.33.2.22 2000/03/05 06:51:06 bill Exp $"
//
// WIN32-specific code for the Fast Light Tool Kit (FLTK).
//
@@ -781,7 +781,7 @@ Fl_X* Fl_X::make(Fl_Window* w) {
case 2: style |= WS_THICKFRAME | WS_MAXIMIZEBOX | WS_CAPTION ; break;
}
if (by+bt) {
- if (!w->non_modal()) style |= WS_SYSMENU | WS_MINIMIZEBOX;
+ if (!w->modal()) style |= WS_SYSMENU | WS_MINIMIZEBOX;
wp += 2*bx;
hp += 2*by+bt;
}
@@ -954,5 +954,5 @@ void Fl_Window::make_current() {
}
//
-// End of "$Id: Fl_win32.cxx,v 1.33.2.21 2000/02/04 06:35:20 bill Exp $".
+// End of "$Id: Fl_win32.cxx,v 1.33.2.22 2000/03/05 06:51:06 bill Exp $".
//
diff --git a/src/filename_list.cxx b/src/filename_list.cxx
index 612c53e0f..d01e32e09 100644
--- a/src/filename_list.cxx
+++ b/src/filename_list.cxx
@@ -1,5 +1,5 @@
//
-// "$Id: filename_list.cxx,v 1.10.2.4 2000/01/27 08:27:26 bill Exp $"
+// "$Id: filename_list.cxx,v 1.10.2.5 2000/03/05 06:51:06 bill Exp $"
//
// Filename list routines for the Fast Light Tool Kit (FLTK).
//
@@ -43,7 +43,7 @@ int filename_list(const char *d, dirent ***list) {
#if defined(__hpux)
// HP-UX defines the comparison function like this:
return scandir(d, list, 0, (int(*)(const dirent **, const dirent **))numericsort);
-#elif HAVE_SCANDIR && !defined(__sgi)
+#elif HAVE_SCANDIR && !defined(__sgi) && !defined(OSF1)
// The vast majority of Unix systems want the sort function to have this
// prototype, most likely so that it can be passed to qsort without any
// changes:
@@ -56,5 +56,5 @@ int filename_list(const char *d, dirent ***list) {
}
//
-// End of "$Id: filename_list.cxx,v 1.10.2.4 2000/01/27 08:27:26 bill Exp $".
+// End of "$Id: filename_list.cxx,v 1.10.2.5 2000/03/05 06:51:06 bill Exp $".
//
diff --git a/src/fl_ask.cxx b/src/fl_ask.cxx
index 36c28b463..90a41ef95 100644
--- a/src/fl_ask.cxx
+++ b/src/fl_ask.cxx
@@ -1,5 +1,5 @@
//
-// "$Id: fl_ask.cxx,v 1.8.2.2 1999/12/30 17:37:05 mike Exp $"
+// "$Id: fl_ask.cxx,v 1.8.2.3 2000/03/05 06:51:07 bill Exp $"
//
// Standard dialog functions for the Fast Light Tool Kit (FLTK).
//
@@ -55,7 +55,10 @@ uchar fl_message_font_ = 0;
uchar fl_message_size_ = FL_NORMAL_SIZE;
static Fl_Window *makeform() {
- if (message_form) return message_form;
+ if (message_form) {
+ message_form->size(410,105);
+ return message_form;
+ }
Fl_Window *w = message_form = new Fl_Window(410,105);
// w->clear_border();
// w->box(FL_UP_BOX);
@@ -72,6 +75,7 @@ static Fl_Window *makeform() {
(button[0] = new Fl_Button(310, 70, 90, 25))->shortcut("^[");
button[1] = new Fl_Return_Button(210, 70, 90, 25);
button[2] = new Fl_Button(110, 70, 90, 25);
+ w->resizable(new Fl_Box(60,10,110-60,22));
w->end();
w->set_modal();
return w;
@@ -228,5 +232,5 @@ const char *fl_password(const char *fmt, const char *defstr, ...) {
}
//
-// End of "$Id: fl_ask.cxx,v 1.8.2.2 1999/12/30 17:37:05 mike Exp $".
+// End of "$Id: fl_ask.cxx,v 1.8.2.3 2000/03/05 06:51:07 bill Exp $".
//