-rw-r--r-- | noncore/settings/sysinfo/sysinfo.pro | 2 | ||||
-rw-r--r-- | noncore/settings/sysinfo/sysloginfo.cpp | 7 |
2 files changed, 6 insertions, 3 deletions
diff --git a/noncore/settings/sysinfo/sysinfo.pro b/noncore/settings/sysinfo/sysinfo.pro index 46d6117..fc754d7 100644 --- a/noncore/settings/sysinfo/sysinfo.pro +++ b/noncore/settings/sysinfo/sysinfo.pro | |||
@@ -22,15 +22,15 @@ SOURCES = main.cpp \ | |||
22 | detail.cpp \ | 22 | detail.cpp \ |
23 | contrib/dhry.c contrib/fft.c \ | 23 | contrib/dhry.c contrib/fft.c \ |
24 | benchmarkinfo.cpp \ | 24 | benchmarkinfo.cpp \ |
25 | sysloginfo.cpp \ | 25 | sysloginfo.cpp \ |
26 | versioninfo.cpp \ | 26 | versioninfo.cpp \ |
27 | sysinfo.cpp | 27 | sysinfo.cpp |
28 | 28 | ||
29 | INCLUDEPATH += $(OPIEDIR)/include | 29 | INCLUDEPATH += $(OPIEDIR)/include |
30 | DEPENDPATH += $(OPIEDIR)/include | 30 | DEPENDPATH += $(OPIEDIR)/include |
31 | LIBS += -lqpe -lopiecore2 -lopieui2 | 31 | LIBS += -lqpe -lopiecore2 -lopieui2 |
32 | DEFINES += UNIX | 32 | DEFINES += UNIX |
33 | TARGET = sysinfo | 33 | TARGET = sysinfo |
34 | VERSION = 1.2.0 | 34 | VERSION = 1.2.1 |
35 | 35 | ||
36 | include( $(OPIEDIR)/include.pro ) | 36 | include( $(OPIEDIR)/include.pro ) |
diff --git a/noncore/settings/sysinfo/sysloginfo.cpp b/noncore/settings/sysinfo/sysloginfo.cpp index 89c04e0..a9e98e3 100644 --- a/noncore/settings/sysinfo/sysloginfo.cpp +++ b/noncore/settings/sysinfo/sysloginfo.cpp | |||
@@ -13,25 +13,26 @@ | |||
13 | ** packaging of this file. | 13 | ** packaging of this file. |
14 | ** | 14 | ** |
15 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE | 15 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE |
16 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | 16 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
17 | ** | 17 | ** |
18 | **********************************************************************/ | 18 | **********************************************************************/ |
19 | 19 | ||
20 | #include "sysloginfo.h" | 20 | #include "sysloginfo.h" |
21 | #include "detail.h" | 21 | #include "detail.h" |
22 | 22 | ||
23 | /* OPIE */ | 23 | /* OPIE */ |
24 | #include <opie2/olistview.h> | 24 | #include <opie2/olistview.h> |
25 | #include <qpe/qpeapplication.h> | 25 | #include <opie2/oconfig.h> |
26 | using namespace Opie::Core; | ||
26 | using namespace Opie::Ui; | 27 | using namespace Opie::Ui; |
27 | 28 | ||
28 | /* QT */ | 29 | /* QT */ |
29 | #include <qcombobox.h> | 30 | #include <qcombobox.h> |
30 | #include <qfile.h> | 31 | #include <qfile.h> |
31 | #include <qlayout.h> | 32 | #include <qlayout.h> |
32 | #include <qmessagebox.h> | 33 | #include <qmessagebox.h> |
33 | #include <qpushbutton.h> | 34 | #include <qpushbutton.h> |
34 | #include <qsocketnotifier.h> | 35 | #include <qsocketnotifier.h> |
35 | #include <qtextbrowser.h> | 36 | #include <qtextbrowser.h> |
36 | #include <qtimer.h> | 37 | #include <qtimer.h> |
37 | #include <qwhatsthis.h> | 38 | #include <qwhatsthis.h> |
@@ -57,25 +58,27 @@ using namespace Opie::Ui; | |||
57 | const unsigned int bufsize = 16384; | 58 | const unsigned int bufsize = 16384; |
58 | char buf[bufsize]; | 59 | char buf[bufsize]; |
59 | 60 | ||
60 | SyslogInfo::SyslogInfo( QWidget* parent, const char* name, WFlags fl ) | 61 | SyslogInfo::SyslogInfo( QWidget* parent, const char* name, WFlags fl ) |
61 | : QWidget( parent, name, fl ) | 62 | : QWidget( parent, name, fl ) |
62 | { | 63 | { |
63 | QGridLayout *layout = new QGridLayout( this ); | 64 | QGridLayout *layout = new QGridLayout( this ); |
64 | layout->setSpacing( 4 ); | 65 | layout->setSpacing( 4 ); |
65 | layout->setMargin( 4 ); | 66 | layout->setMargin( 4 ); |
66 | 67 | ||
67 | syslogview = new QTextView( this ); | 68 | syslogview = new QTextView( this ); |
68 | syslogview->setTextFormat( PlainText ); | 69 | syslogview->setTextFormat( PlainText ); |
69 | syslogview->setFont( QFont( "Fixed" ) ); | 70 | OConfig cfg( "qpe" ); |
71 | cfg.setGroup( "Appearance" ); | ||
72 | syslogview->setFont( QFont( "Fixed", cfg.readNumEntry( "FontSize", 10 ) ) ); | ||
70 | layout->addWidget( syslogview, 0, 0 ); | 73 | layout->addWidget( syslogview, 0, 0 ); |
71 | syslogview->setText( "..." ); | 74 | syslogview->setText( "..." ); |
72 | 75 | ||
73 | memset( buf, 0, bufsize ); | 76 | memset( buf, 0, bufsize ); |
74 | ::klogctl( SYSLOG_READ_ALL, buf, bufsize ); | 77 | ::klogctl( SYSLOG_READ_ALL, buf, bufsize ); |
75 | syslogview->setText( buf ); | 78 | syslogview->setText( buf ); |
76 | 79 | ||
77 | #ifdef APPEND | 80 | #ifdef APPEND |
78 | fd = ::open( "/proc/kmsg", O_RDONLY|O_SYNC ); | 81 | fd = ::open( "/proc/kmsg", O_RDONLY|O_SYNC ); |
79 | if ( fd == -1 ) | 82 | if ( fd == -1 ) |
80 | { | 83 | { |
81 | syslogview->setText( "Couldn't open /proc/kmsg: " + QString( strerror( errno ) ) ); | 84 | syslogview->setText( "Couldn't open /proc/kmsg: " + QString( strerror( errno ) ) ); |