diff --git a/__init__.py b/__init__.py index 8570529b..3ee3e760 100644 --- a/__init__.py +++ b/__init__.py @@ -312,12 +312,6 @@ def initialize(self): self.log.warning('Could not prepare forecasts. ' '({})'.format(repr(e))) - # Register for handling idle/resting screen - msg_type = '{}.{}'.format(self.skill_id, 'idle') - self.add_event(msg_type, self.handle_idle) - self.add_event('mycroft.mark2.collect_idle', - self.handle_collect_request) - # self.test_screen() # DEBUG: Used during screen testing/debugging def test_screen(self): @@ -365,14 +359,6 @@ def schedule_for_daily_use(self): 60*60*24+60*15, # One day + 15 minutes name="precache3") - def handle_collect_request(self, message): - self.bus.emit(Message('mycroft.mark2.register_idle', - data={'name': 'Weather', - 'id': self.skill_id})) - - def handle_idle(self, message): - self.gui.show_page('idle.qml') - def get_coming_days_forecast(self, forecast, unit, days=None): """ Get weather forcast for the coming days and returns them as a list diff --git a/ui/idle.qml b/ui/idle.qml deleted file mode 100644 index 0bd579ab..00000000 --- a/ui/idle.qml +++ /dev/null @@ -1,43 +0,0 @@ -import QtQuick.Layouts 1.4 -import QtQuick 2.4 -import QtQuick.Controls 2.0 -import org.kde.kirigami 2.4 as Kirigami - -import Mycroft 1.0 as Mycroft -import org.kde.lottie 1.0 - -WeatherDelegate { - id: root - - spacing: proportionalGridUnit * 5 - - LottieAnimation { - id: weatherAnimation - Layout.alignment: Qt.AlignHCenter - Layout.preferredWidth: Math.min(root.contentWidth, proportionalGridUnit * 50) - Layout.preferredHeight: Layout.preferredWidth - - source: Qt.resolvedUrl(getWeatherImagery(sessionData.weathercode)) - - loops: Animation.Infinite - fillMode: Image.PreserveAspectFit - running: true - - // Debug: - onSourceChanged: { - console.log(getWeatherImagery(sessionData.weathercode)); - } - onStatusChanged: { - console.log(weatherAnimation.status, errorString); - } - } - - Mycroft.AutoFitLabel { - id: temperature - font.weight: Font.Bold - Layout.fillWidth: true - Layout.preferredHeight: proportionalGridUnit * 40 - rightPadding: -font.pixelSize * 0.1 - text: sessionData.current + "°" - } -}