Logo Search packages:      
Sourcecode: agave version File versions  Download package

bool gcs::Widgets::ColorSwatch::on_button_press_event ( GdkEventButton *  e  )  [protected, virtual]

Handles the action of pressing a mouse button on a ColorSwatch object. Will pop up a context menu if one is defined, else will do nothing

Reimplemented in gcs::Widgets::TextSwatch.

Definition at line 172 of file gcs-colorswatch.cc.

        {
            //Then do our custom stuff:
            if (e->type == GDK_BUTTON_PRESS)
            {
                // User pressed left mouse button
                if (e->button == 1)
                {
                    // let listeners know that we've been selected
                    m_signal_selected.emit();
                }
            }
            return false;
        }


Generated by  Doxygen 1.6.0   Back to index