# Path: rtlsdr_scanner/events.py
# def post_event(destination, status):
#     if isinstance(destination, Queue.Queue):
#         destination.put(status)
#     elif isinstance(destination, wx.EvtHandler):
#         wx.PostEvent(destination, status)
# 
# class EventThread(wx.PyEvent):
#     def __init__(self, status, arg1=None, arg2=None):
#         wx.PyEvent.__init__(self)
#         self.SetEventType(EVENT_THREAD)
#         self.data = Status(status, arg1, arg2)
# 
# class Event(object):
#     STARTING, STEPS, INFO, DATA, STOPPED, ERROR, FINISHED, PROCESSED, \
#         CAL, LEVEL, UPDATED, DRAW, \
#         DELAY_COUNT, DELAY_START, \
#         LOC, LOC_RAW, LOC_WARN, LOC_ERR, LOC_SAT = range(19)


import threading
import time
from matplotlib.ticker import ScalarFormatter, AutoMinorLocator
from rtlsdr_scanner.events import post_event, EventThread, Event
from rtlsdr_scanner.utils_mpl import utc_to_mpl, set_date_ticks
        pass

    def scale_plot(self, force=False):
        if self.figure is not None and self.plot is not None:
            if self.settings.autoT or force:
                times = self.plot[0].get_data()[0]
                tMin = min(times)
                tMax = max(times)
                if tMin == tMax:
                    tMax += utc_to_mpl(10)
                self.axes.set_xlim(tMin, tMax)
            if self.settings.autoL or force:
                self.axes.autoscale(True, 'y', True)

    def get_axes(self):
        return self.axes

    def get_axes_bar(self):
        return None

    def get_bar(self):
        return self.barBase

    def get_plot_thread(self):
        return self.threadPlot

    def set_title(self, title):
        self.axes.set_title(title, fontsize='medium')

    def set_plot(self, spectrum, extent, _annotate=False):

# Path: rtlsdr_scanner/events.py
# def post_event(destination, status):
#     if isinstance(destination, Queue.Queue):
#         destination.put(status)
#     elif isinstance(destination, wx.EvtHandler):
#         wx.PostEvent(destination, status)
# 
# class EventThread(wx.PyEvent):
#     def __init__(self, status, arg1=None, arg2=None):
#         wx.PyEvent.__init__(self)
#         self.SetEventType(EVENT_THREAD)
#         self.data = Status(status, arg1, arg2)
# 
# class Event(object):
#     STARTING, STEPS, INFO, DATA, STOPPED, ERROR, FINISHED, PROCESSED, \
#         CAL, LEVEL, UPDATED, DRAW, \
#         DELAY_COUNT, DELAY_START, \
#         LOC, LOC_RAW, LOC_WARN, LOC_ERR, LOC_SAT = range(19)


# Path: rtlsdr_scanner/plot_time.py
import threading
import time
from matplotlib.ticker import ScalarFormatter, AutoMinorLocator
from rtlsdr_scanner.events import post_event, EventThread, Event
from rtlsdr_scanner.utils_mpl import utc_to_mpl, set_date_ticks

        pass

    def scale_plot(self, force=False):
        if self.figure is not None and self.plot is not None:
            if self.settings.autoT or force:
                times = self.plot[0].get_data()[0]
                tMin = min(times)
                tMax = max(times)
                if tMin == tMax:
                    tMax += utc_to_mpl(10)
                self.axes.set_xlim(tMin, tMax)
            if self.settings.autoL or force:
                self.axes.autoscale(True, 'y', True)

    def get_axes(self):
        return self.axes

    def get_axes_bar(self):
        return None

    def get_bar(self):
        return self.barBase

    def get_plot_thread(self):
        return self.threadPlot

    def set_title(self, title):
        self.axes.set_title(title, fontsize='medium')

    def set_plot(self, spectrum, extent, _annotate=False):

        self.threadPlot = ThreadPlot(self, self.settings, self.axes,