projects
/
goodguy
/
history.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
igor ru.po
[goodguy/history.git]
/
cinelerra-5.1
/
guicast
/
bclistbox.C
diff --git
a/cinelerra-5.1/guicast/bclistbox.C
b/cinelerra-5.1/guicast/bclistbox.C
index 3b1332923fcc9953e21374d060afe169960a0254..88d4b09470a8337a470f11f664f26b9e7edbf945 100644
(file)
--- a/
cinelerra-5.1/guicast/bclistbox.C
+++ b/
cinelerra-5.1/guicast/bclistbox.C
@@
-432,6
+432,7
@@
BC_ListBox::BC_ListBox(int x,
// reset the search engine
//printf("BC_ListBox::BC_ListBox 4\n");
// reset the search engine
//printf("BC_ListBox::BC_ListBox 4\n");
+ show_query = 0;
reset_query();
//printf("BC_ListBox::BC_ListBox 5\n");
}
reset_query();
//printf("BC_ListBox::BC_ListBox 5\n");
}
@@
-2479,12
+2480,11
@@
int BC_ListBox::repeat_event(int64_t duration)
case NO_OPERATION:
// Show tooltip
case NO_OPERATION:
// Show tooltip
- if(button_highlighted && is_popup &&
!tooltip_done &&
+ if(button_highlighted && is_popup &&
tooltip_text && tooltip_text[0] != 0 &&
duration == get_resources()->tooltip_delay)
{
show_tooltip();
tooltip_text && tooltip_text[0] != 0 &&
duration == get_resources()->tooltip_delay)
{
show_tooltip();
- tooltip_done = 1;
return 1;
}
break;
return 1;
}
break;
@@
-3942,6
+3942,7
@@
int BC_ListBox::reposition_window(int x, int y, int w, int h, int flush)
int BC_ListBox::deactivate()
{
int BC_ListBox::deactivate()
{
+ hide_tooltip();
// printf("BC_ListBox::deactivate %d this=%p gui=%p active=%d\n",
// __LINE__,
// this,
// printf("BC_ListBox::deactivate %d this=%p gui=%p active=%d\n",
// __LINE__,
// this,
@@
-3978,6
+3979,7
@@
int BC_ListBox::deactivate()
int BC_ListBox::activate(int take_focus)
{
if( active ) return 0;
int BC_ListBox::activate(int take_focus)
{
if( active ) return 0;
+ active = 1;
if( take_focus )
set_active_subwindow(this);
button_releases = 0;
if( take_focus )
set_active_subwindow(this);
button_releases = 0;
@@
-3996,11
+3998,11
@@
int BC_ListBox::activate(int take_focus)
int BC_ListBox::activate(int x, int y, int w, int h)
{
int BC_ListBox::activate(int x, int y, int w, int h)
{
- if( active || !is_popup || gui ) return 0;
+ if( !is_popup || gui ) return 0;
+ active = 1;
if(w != -1) popup_w = w;
if(h != -1) popup_h = h;
reset_query();
if(w != -1) popup_w = w;
if(h != -1) popup_h = h;
reset_query();
- active = 1;
if( y + popup_h > top_level->get_root_h(0) )
y -= get_h() + popup_h;
add_subwindow(gui = new BC_Popup(this,
if( y + popup_h > top_level->get_root_h(0) )
y -= get_h() + popup_h;
add_subwindow(gui = new BC_Popup(this,
@@
-4030,7
+4032,6
@@
int BC_ListBox::keypress_event()
{
case ESC:
case RETURN:
{
case ESC:
case RETURN:
- case BACKSPACE:
top_level->deactivate();
// If user is manipulating popup with keyboard, don't pass on event.
top_level->deactivate();
// If user is manipulating popup with keyboard, don't pass on event.
@@
-4131,7
+4132,12
@@
int BC_ListBox::keypress_event()
if(query_len > 0) query[--query_len] = 0;
new_selection = query_list();
}
if(query_len > 0) query[--query_len] = 0;
new_selection = query_list();
}
-
+ if( show_query ) {
+ if( query_len > 0 )
+ show_tooltip(query);
+ else
+ hide_tooltip();
+ }
redraw = 1;
result = 1;
}
redraw = 1;
result = 1;
}