-Updated tooltips: needs some UI work, but backend working fine

main
Harry van Haaren 2013-07-25 17:53:59 +01:00
parent 3f17e33e32
commit 3bcbbefd0d
3 changed files with 15 additions and 1 deletions

View File

@ -36,6 +36,8 @@
#include "../eventhandler.hxx"
extern void luppp_tooltip(std::string s);
namespace Avtk
{
@ -383,6 +385,9 @@ class ClipSelector : public Fl_Button
return 1;
case FL_ENTER:
mouseOver = true;
// push help string to UI tooltip area
luppp_tooltip( "Clip selector" );
redraw();
return 1;
case FL_LEAVE:

View File

@ -28,6 +28,8 @@
#include <valarray>
#include <string>
extern void luppp_tooltip(std::string s);
namespace Avtk
{
@ -206,6 +208,10 @@ class Volume : public Fl_Slider
}
}
return 1;
case FL_ENTER:
// push help string to UI tooltip area
luppp_tooltip( "Volume" );
return 1;
case FL_RELEASE:
if (highlight) {
highlight = 0;

View File

@ -55,7 +55,10 @@ Gui::Gui() :
Avtk::Image* headerImage = new Avtk::Image(0,0,1110,36,"header.png");
headerImage->setPixbuf( header.pixel_data, 4 );
//tooltipLabel = new Fl_Box(100, 20, 200, 20, "tooltips go here");
tooltipLabel = new Fl_Box(90, 15, 200, 20, "");
tooltipLabel->labelcolor( FL_LIGHT2 );
tooltipLabel->color( FL_DARK2 );
int i = 0;
for (; i < NTRACKS; i++ )