Make sure Fl::event_text() is not NULL. (STR #70)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3030 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
1bde669d75
commit
7f15f8d97f
2
CHANGES
2
CHANGES
@ -1,5 +1,7 @@
|
||||
CHANGES IN FLTK 1.1.4
|
||||
|
||||
- Fl::event_text() was sometimes initialized to NULL
|
||||
instead of an empty string (STR #70)
|
||||
- fl_draw() didn't properly handle a trailing escaped
|
||||
"@" character (STR #84)
|
||||
- Added documentation for all forms of
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Fl_mac.cxx,v 1.1.2.46 2003/06/09 18:53:06 matthiaswm Exp $"
|
||||
// "$Id: Fl_mac.cxx,v 1.1.2.47 2003/06/15 04:27:35 easysw Exp $"
|
||||
//
|
||||
// MacOS specific code for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -1857,12 +1857,13 @@ void Fl::paste(Fl_Widget &receiver, int clipboard) {
|
||||
}
|
||||
Fl::e_text = fl_selection_buffer[clipboard];
|
||||
Fl::e_length = fl_selection_length[clipboard];
|
||||
if (!Fl::e_text) Fl::e_text = (char *)"";
|
||||
receiver.handle(FL_PASTE);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// End of "$Id: Fl_mac.cxx,v 1.1.2.46 2003/06/09 18:53:06 matthiaswm Exp $".
|
||||
// End of "$Id: Fl_mac.cxx,v 1.1.2.47 2003/06/15 04:27:35 easysw Exp $".
|
||||
//
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Fl_win32.cxx,v 1.33.2.37.2.46 2003/06/12 01:36:18 easysw Exp $"
|
||||
// "$Id: Fl_win32.cxx,v 1.33.2.37.2.47 2003/06/15 04:27:35 easysw Exp $"
|
||||
//
|
||||
// WIN32-specific code for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -397,6 +397,8 @@ void Fl::paste(Fl_Widget &receiver, int clipboard) {
|
||||
// called in response to FL_PASTE!
|
||||
Fl::e_text = fl_selection_buffer[clipboard];
|
||||
Fl::e_length = fl_selection_length[clipboard];
|
||||
|
||||
if (!Fl::e_text) Fl::e_text = (char *)"";
|
||||
receiver.handle(FL_PASTE);
|
||||
} else {
|
||||
if (!OpenClipboard(NULL)) return;
|
||||
@ -1193,5 +1195,5 @@ void Fl_Window::make_current() {
|
||||
}
|
||||
|
||||
//
|
||||
// End of "$Id: Fl_win32.cxx,v 1.33.2.37.2.46 2003/06/12 01:36:18 easysw Exp $".
|
||||
// End of "$Id: Fl_win32.cxx,v 1.33.2.37.2.47 2003/06/15 04:27:35 easysw Exp $".
|
||||
//
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Fl_x.cxx,v 1.24.2.24.2.29 2003/05/04 21:45:46 easysw Exp $"
|
||||
// "$Id: Fl_x.cxx,v 1.24.2.24.2.30 2003/06/15 04:27:35 easysw Exp $"
|
||||
//
|
||||
// X specific code for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -397,6 +397,7 @@ void Fl::paste(Fl_Widget &receiver, int clipboard) {
|
||||
// called in response to FL_PASTE!
|
||||
Fl::e_text = fl_selection_buffer[clipboard];
|
||||
Fl::e_length = fl_selection_length[clipboard];
|
||||
if (!Fl::e_text) Fl::e_text = (char *)"";
|
||||
receiver.handle(FL_PASTE);
|
||||
return;
|
||||
}
|
||||
@ -552,7 +553,7 @@ int fl_handle(const XEvent& thisevent)
|
||||
bytesread += count*format/8;
|
||||
if (!remaining) break;
|
||||
}
|
||||
Fl::e_text = (char*)buffer;
|
||||
Fl::e_text = buffer ? (char*)buffer : (char *)"";
|
||||
Fl::e_length = bytesread;
|
||||
fl_selection_requestor->handle(FL_PASTE);
|
||||
// Detect if this paste is due to Xdnd by the property name (I use
|
||||
@ -1267,5 +1268,5 @@ void Fl_Window::make_current() {
|
||||
#endif
|
||||
|
||||
//
|
||||
// End of "$Id: Fl_x.cxx,v 1.24.2.24.2.29 2003/05/04 21:45:46 easysw Exp $".
|
||||
// End of "$Id: Fl_x.cxx,v 1.24.2.24.2.30 2003/06/15 04:27:35 easysw Exp $".
|
||||
//
|
||||
|
Loading…
Reference in New Issue
Block a user