MCPcopy Create free account
hub / github.com/donkeyteethUX/iced_plot / handle_mouse_click

Method handle_mouse_click

src/plot_state.rs:808–831  ·  view source on GitHub ↗
(
        &mut self,
        button: mouse::Button,
        widget: &PlotWidget,
        publish_hover_pick: &mut Option<HoverPickEvent>,
    )

Source from the content-addressed store, hash-verified

806 return false;
807 }
808
809 let keyboard::Event::KeyPressed { key, .. } = event else {
810 return false;
811 };
812
813 if !cursor_over {
814 return false;
815 }
816
817 match widget.controls.key_action(key) {
818 Some(KeyAction::Autoscale) => {
819 self.autoscale(true);
820 true
821 }
822 Some(KeyAction::PanBy {
823 direction,
824 fraction,
825 }) => {
826 self.pan_by(direction, fraction);
827 true
828 }
829 _ => false,
830 }
831 }
832
833 fn update_axis_links(&mut self) {
834 if let Some(ref link) = self.x_axis_link {

Callers 1

handle_mouse_eventMethod · 0.80

Calls 4

is_double_clickMethod · 0.80
double_click_actionMethod · 0.80
click_actionMethod · 0.80
apply_click_actionMethod · 0.80

Tested by

no test coverage detected