Entropy Piano Tuner  1.1.3 (documentation not yet complete)
An open-source experimental software for piano tuning by entropy minimization
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
AutoClosingMessageBox Class Reference

a dialog that will automatically close on a event (message). More...

#include <autoclosingmessagebox.h>

+ Inheritance diagram for AutoClosingMessageBox:
+ Collaboration diagram for AutoClosingMessageBox:

Public Types

enum  CloseReason { MSG_RECORDING_STARTED }
 Reasons for the dialog to close automatically. More...

Public Member Functions

 AutoClosingMessageBox (QWidget *parent, CloseReason closeReason, Icon icon, const QString &title, const QString &text, StandardButton buttons=StandardButton::Ok)
 Constructor. More...
 ~AutoClosingMessageBox ()
 Destructor. More...
- Public Member Functions inherited from MessageListener
 MessageListener (bool defaultActivation=true)
virtual ~MessageListener ()
bool isMessageListenerActive () const
void activateMessageListener ()
void deactivateMessageListener ()

Protected Member Functions

virtual void handleMessage (MessagePtr m) overridefinal
 Message handling. More...
virtual void closeEvent (QCloseEvent *e) overridefinal
 Reimplementation of the close event. More...

Private Member Functions

virtual int exec () overridefinal
 Executing of the dialog is forbidden. More...

Private Attributes

const CloseReason mCloseReason
 Reason to close the dialog automatically. More...

Detailed Description

a dialog that will automatically close on a event (message).

Not that you have to create this message box with new. It will delete itself on closing.

Definition at line 33 of file autoclosingmessagebox.h.

Member Enumeration Documentation

Reasons for the dialog to close automatically.



Definition at line 39 of file autoclosingmessagebox.h.

Constructor & Destructor Documentation

AutoClosingMessageBox::AutoClosingMessageBox ( QWidget *  parent,
CloseReason  closeReason,
Icon  icon,
const QString &  title,
const QString &  text,
StandardButton  buttons = StandardButton::Ok 


parent: The parent widget
closeReason: A reason to close the dialog automatically
icon: An default icon to be displayed in the message box
title: The title that shall be displayed
text: An informative text to be displayed
buttons: A standard button to be added

Definition at line 23 of file autoclosingmessagebox.cpp.

AutoClosingMessageBox::~AutoClosingMessageBox ( )


Definition at line 30 of file autoclosingmessagebox.cpp.

Member Function Documentation

void AutoClosingMessageBox::closeEvent ( QCloseEvent *  e)

Reimplementation of the close event.

The function will delete this.

e: The event

Definition at line 47 of file autoclosingmessagebox.cpp.

int AutoClosingMessageBox::exec ( )

Executing of the dialog is forbidden.

Do not call this function. The dialog has to be created with new to be global. It will delete itself upon closing.


Definition at line 52 of file autoclosingmessagebox.cpp.

void AutoClosingMessageBox::handleMessage ( MessagePtr  m)

Message handling.

m: The message to handle

Implements MessageListener.

Definition at line 35 of file autoclosingmessagebox.cpp.

Member Data Documentation

const CloseReason AutoClosingMessageBox::mCloseReason

Reason to close the dialog automatically.

Definition at line 93 of file autoclosingmessagebox.h.

The documentation for this class was generated from the following files: