Provide a keybinding/menu entry for track renaming.
This commit is contained in:
parent
8545b82b49
commit
869cf25b3b
|
@ -48,6 +48,14 @@ public:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
virtual void
|
||||||
|
take_focus ( void )
|
||||||
|
{
|
||||||
|
set_visible_focus();
|
||||||
|
Fl_Widget::take_focus();
|
||||||
|
clear_visible_focus();
|
||||||
|
}
|
||||||
|
|
||||||
virtual int
|
virtual int
|
||||||
handle ( int m )
|
handle ( int m )
|
||||||
{
|
{
|
||||||
|
@ -59,11 +67,9 @@ public:
|
||||||
redraw();
|
redraw();
|
||||||
return 1;
|
return 1;
|
||||||
case FL_PUSH:
|
case FL_PUSH:
|
||||||
set_visible_focus();
|
|
||||||
take_focus();
|
take_focus();
|
||||||
clear_visible_focus();
|
|
||||||
redraw();
|
redraw();
|
||||||
return r;
|
return 1;
|
||||||
case FL_UNFOCUS:
|
case FL_UNFOCUS:
|
||||||
|
|
||||||
if ( window() )
|
if ( window() )
|
||||||
|
|
|
@ -653,6 +653,10 @@ Track::menu_cb ( const Fl_Menu_ *m )
|
||||||
Fl::delete_widget( this );
|
Fl::delete_widget( this );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if ( ! strcmp( picked, "/Rename" ) )
|
||||||
|
{
|
||||||
|
((Fl_Sometimes_Input*)name_field)->take_focus();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#include "FL/menu_popup.H"
|
#include "FL/menu_popup.H"
|
||||||
|
@ -676,6 +680,7 @@ Track::menu ( void ) const
|
||||||
{ "Add Control", 0, 0, 0 },
|
{ "Add Control", 0, 0, 0 },
|
||||||
{ "Add Annotation", 0, 0, 0 },
|
{ "Add Annotation", 0, 0, 0 },
|
||||||
{ "Color", 0, 0, 0 },
|
{ "Color", 0, 0, 0 },
|
||||||
|
{ "Rename", FL_CTRL + 'n', 0, 0 },
|
||||||
{ "Remove", 0, 0, 0 }, // transport->rolling ? FL_MENU_INACTIVE : 0 },
|
{ "Remove", 0, 0, 0 }, // transport->rolling ? FL_MENU_INACTIVE : 0 },
|
||||||
{ 0 },
|
{ 0 },
|
||||||
};
|
};
|
||||||
|
|
|
@ -48,7 +48,6 @@ class Port;
|
||||||
class Audio_Region;
|
class Audio_Region;
|
||||||
class Audio_File;
|
class Audio_File;
|
||||||
|
|
||||||
|
|
||||||
//class Audio_Sequence;
|
//class Audio_Sequence;
|
||||||
|
|
||||||
#include "Audio_Sequence.H"
|
#include "Audio_Sequence.H"
|
||||||
|
|
Loading…
Reference in New Issue