This function checks the plot type and applies specific modifications to the plot object based on the provided parameters.
apply_plot_modifications(plot_obj, plot_type, dblclicking, ranges)The original plot object.
The type of the plot, either gg (ggplot2) or grob (grid, graphics).
A logical value indicating whether double-clicking on data points on the main plot is enabled or disabled.
A list containing x and y values of ranges.