Difference between revisions of "Notification Center"

From MythTV Official Wiki
Jump to: navigation, search
(Service API)
(remove 0.27 pre comment)
 
(One intermediate revision by one user not shown)
Line 1: Line 1:
This page describes the new Notification Center engine introduced in 0.27 and currently available in 0.27-pre development version.
+
This page describes the new Notification Center engine available in 0.27 and above.
 
+
{{Note box|This feature is only available in the 0.27-pre development version of MythTV}}
+
  
 
== Introduction ==
 
== Introduction ==
Line 60: Line 58:
  
 
* MythNotification
 
* MythNotification
* MythUINotificationCenter
+
* MythNotificationCenter
  
A MythNotification is passed to the MythUINotificationCenter singleton.
+
A MythNotification is passed to the MythNotificationCenter singleton.
  
 
Class [http://code.mythtv.org/doxygen/classMythNotification.html MythNotification]
 
Class [http://code.mythtv.org/doxygen/classMythNotification.html MythNotification]
  
Class [http://code.mythtv.org/doxygen/classMythUINotificationCenter.html MythUINotificationCenter]
+
Class [http://code.mythtv.org/doxygen/classMythNotificationCenter.html MythNotificationCenter]

Latest revision as of 16:52, 19 October 2013

This page describes the new Notification Center engine available in 0.27 and above.

Introduction

The Notification Center is a new interface designed to provide users with various information related to the state of MythTV. Error messages will now appear in the Notification Center.

AirPlay will use the Notification Center to display connection status, information about the song being played, including album artwork.

A notification can be dismissed by pressing escape (or exit).

Screen shots

Developer API

There are several APIs available for programmers to make full use of the Notification Center.

A notification is made of three main components.

  • title
  • origin
  • description

A notification can have four types:

  • normal
  • error
  • warning
  • check

Normal type notification can also have these extra components set:

  • image
  • progress (floating point value between 0 and 1)
  • extra text
  • progress text

All components are optional; however, we strongly recommend to always have a title and an origin. Extra text and progress text are only displayed if a progress bar is set. The progress bar will appear if progress is given a value between 0 and 1. A negative value indicates that no progress bar is to be displayed.

A notification can be made to be displayed in full screen.

Additionally there are 4 types of notification

MythNotification

Using the UDP interface, see MythNotification

Service API

Two different services are available to send notifications

The Frontend service

The Myth service

C++ API

There are two core classes:

  • MythNotification
  • MythNotificationCenter

A MythNotification is passed to the MythNotificationCenter singleton.

Class MythNotification

Class MythNotificationCenter