From 2c38847e01161b7e4720271b1b17e79007334855 Mon Sep 17 00:00:00 2001 From: Ray-V Date: Wed, 10 Feb 2021 10:59:53 +0900 Subject: [PATCH] Save and restore status of numpad between startups. This refers to PR #9. Signed-off-by: Ray-V Signed-off-by: Michele Calgaro (cherry picked from commit d1fca948cfde3b711652e69e03084908facc9f83) --- src/MainWidget.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/MainWidget.cpp b/src/MainWidget.cpp index 4008f49..0ca175b 100644 --- a/src/MainWidget.cpp +++ b/src/MainWidget.cpp @@ -76,6 +76,11 @@ MainWidget::MainWidget ( TDEAboutData *about, bool tren, TQWidget *parent, const int stx=15; int sty=15; extent_visible=false; + TDEConfig *cfg = TDEApplication::kApplication()->config(); + if (cfg) + { + extent_visible = cfg->readBoolEntry("numpad_visible", false); + } // resize ( 550,235 ); // move(0,0); @@ -611,6 +616,7 @@ void MainWidget::hideEvent ( TQHideEvent * ) cfg = TDEApplication::kApplication()->config(); if (cfg){ cfg->writeEntry("geometry",geometry()); + cfg->writeEntry("numpad_visible",extent_visible); cfg->sync(); } }