diff options
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | src/Screen.cc | 3 | ||||
-rw-r--r-- | src/fluxbox.cc | 15 |
3 files changed, 11 insertions, 10 deletions
@@ -1,5 +1,8 @@ | |||
1 | (Format: Year/Month/Day) | 1 | (Format: Year/Month/Day) |
2 | Changes for 1.0.1: | 2 | Changes for 1.0.1: |
3 | *08/04/31: | ||
4 | * Notice when user replaces a non-existent menu file (Mark) | ||
5 | fluxbox.cc Screen.cc | ||
3 | *08/04/30: | 6 | *08/04/30: |
4 | * Don't allow empty root menu (Mark) | 7 | * Don't allow empty root menu (Mark) |
5 | Screen.cc | 8 | Screen.cc |
diff --git a/src/Screen.cc b/src/Screen.cc index cb6faf2..f06fc43 100644 --- a/src/Screen.cc +++ b/src/Screen.cc | |||
@@ -1536,6 +1536,9 @@ void BScreen::initMenu() { | |||
1536 | restart_fb); | 1536 | restart_fb); |
1537 | m_rootmenu->insert(_FB_XTEXT(Menu, Exit, "Exit", "Exit command"), | 1537 | m_rootmenu->insert(_FB_XTEXT(Menu, Exit, "Exit", "Exit command"), |
1538 | exit_fb); | 1538 | exit_fb); |
1539 | // still save the menu filename, in case it becomes valid later | ||
1540 | if (!fb->getMenuFilename().empty()) | ||
1541 | fb->saveMenuFilename(fb->getMenuFilename().c_str()); | ||
1539 | } | 1542 | } |
1540 | 1543 | ||
1541 | m_rootmenu->updateMenu(); | 1544 | m_rootmenu->updateMenu(); |
diff --git a/src/fluxbox.cc b/src/fluxbox.cc index a6ce035..300d683 100644 --- a/src/fluxbox.cc +++ b/src/fluxbox.cc | |||
@@ -1476,10 +1476,7 @@ bool Fluxbox::menuTimestampsChanged() const { | |||
1476 | 1476 | ||
1477 | time_t timestamp = FbTk::FileUtil::getLastStatusChangeTimestamp((*it)->filename.c_str()); | 1477 | time_t timestamp = FbTk::FileUtil::getLastStatusChangeTimestamp((*it)->filename.c_str()); |
1478 | 1478 | ||
1479 | if (timestamp >= 0) { | 1479 | if (timestamp != (*it)->timestamp) |
1480 | if (timestamp != (*it)->timestamp) | ||
1481 | return true; | ||
1482 | } else | ||
1483 | return true; | 1480 | return true; |
1484 | } | 1481 | } |
1485 | 1482 | ||
@@ -1529,14 +1526,12 @@ void Fluxbox::saveMenuFilename(const char *filename) { | |||
1529 | if (! found) { | 1526 | if (! found) { |
1530 | time_t timestamp = FbTk::FileUtil::getLastStatusChangeTimestamp(filename); | 1527 | time_t timestamp = FbTk::FileUtil::getLastStatusChangeTimestamp(filename); |
1531 | 1528 | ||
1532 | if (timestamp >= 0) { | 1529 | MenuTimestamp *ts = new MenuTimestamp; |
1533 | MenuTimestamp *ts = new MenuTimestamp; | ||
1534 | 1530 | ||
1535 | ts->filename = filename; | 1531 | ts->filename = filename; |
1536 | ts->timestamp = timestamp; | 1532 | ts->timestamp = timestamp; |
1537 | 1533 | ||
1538 | m_menu_timestamps.push_back(ts); | 1534 | m_menu_timestamps.push_back(ts); |
1539 | } | ||
1540 | } | 1535 | } |
1541 | } | 1536 | } |
1542 | 1537 | ||