mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-10-19 17:11:15 +02:00
2018-08-15 Fred Gleason <fredg@paravelsystems.com>
* Fixed style inconsistencies in dialogs within rdgpimon(1). * Fixed style inconsistencies in dialogs within rdpopup(1).
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
//
|
||||
// A utility for displaying messages on the desktop
|
||||
//
|
||||
// (C) Copyright 2009,2016-2018 Fred Gleason <fredg@paravelsystems.com>
|
||||
// (C) Copyright 2009-2018 Fred Gleason <fredg@paravelsystems.com>
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License version 2 as
|
||||
@@ -32,6 +32,11 @@
|
||||
|
||||
#include <rdpopup.h>
|
||||
|
||||
//
|
||||
// Icons
|
||||
//
|
||||
#include "../icons/rivendell-22x22.xpm"
|
||||
|
||||
QString WordWrap(const QString &str)
|
||||
{
|
||||
QString ret;
|
||||
@@ -85,34 +90,36 @@ int main(int argc,char *argv[])
|
||||
QDateTime dt=QDateTime(QDate::currentDate(),QTime::currentTime());
|
||||
QString msg=WordWrap(argv[argc-1]);
|
||||
QMessageBox *mb;
|
||||
|
||||
switch(prio) {
|
||||
case 1:
|
||||
mb=new QMessageBox(dt.toString("MM/dd @ hh:mm"),msg,
|
||||
QMessageBox::Information,
|
||||
QMessageBox::Ok,QMessageBox::
|
||||
NoButton,QMessageBox::NoButton);
|
||||
break;
|
||||
case 1:
|
||||
mb=new QMessageBox(dt.toString("MM/dd @ hh:mm"),msg,
|
||||
QMessageBox::Information,
|
||||
QMessageBox::Ok,QMessageBox::
|
||||
NoButton,QMessageBox::NoButton);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
mb=new QMessageBox(dt.toString("MM/dd @ hh:mm"),msg,
|
||||
QMessageBox::Warning,QMessageBox::Ok,
|
||||
QMessageBox::NoButton,QMessageBox::NoButton);
|
||||
break;
|
||||
case 2:
|
||||
mb=new QMessageBox(dt.toString("MM/dd @ hh:mm"),msg,
|
||||
QMessageBox::Warning,QMessageBox::Ok,
|
||||
QMessageBox::NoButton,QMessageBox::NoButton);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
mb=new QMessageBox(dt.toString("MM/dd @ hh:mm"),msg,
|
||||
QMessageBox::Critical,QMessageBox::Ok,
|
||||
QMessageBox::NoButton,QMessageBox::NoButton);
|
||||
break;
|
||||
case 3:
|
||||
mb=new QMessageBox(dt.toString("MM/dd @ hh:mm"),msg,
|
||||
QMessageBox::Critical,QMessageBox::Ok,
|
||||
QMessageBox::NoButton,QMessageBox::NoButton);
|
||||
break;
|
||||
|
||||
default:
|
||||
mb=new QMessageBox(dt.toString("MM/dd @ hh:mm"),msg,
|
||||
QMessageBox::Information,
|
||||
QMessageBox::Ok,QMessageBox::NoButton,
|
||||
QMessageBox::NoButton);
|
||||
break;
|
||||
default:
|
||||
mb=new QMessageBox(dt.toString("MM/dd @ hh:mm"),msg,
|
||||
QMessageBox::Information,
|
||||
QMessageBox::Ok,QMessageBox::NoButton,
|
||||
QMessageBox::NoButton);
|
||||
break;
|
||||
}
|
||||
QFont font("hevetica",16,QFont::Bold);
|
||||
mb->setWindowIcon(QPixmap(rivendell_22x22_xpm));
|
||||
QFont font("helvetica",16,QFont::Bold);
|
||||
font.setPixelSize(16);
|
||||
mb->setFont(font);
|
||||
mb->exec();
|
||||
|
Reference in New Issue
Block a user