From 59efe58fb6552e3167daa63abf621ad16d0b1b1a Mon Sep 17 00:00:00 2001 From: Duncan Mac-Vicar P Date: Thu, 7 Aug 2008 20:03:11 +0000 Subject: [PATCH] implement relogin suggested --- zypp/Patch.cc | 4 ++++ zypp/Patch.h | 6 ++++++ zypp/sat/SolvAttr.cc | 1 + zypp/sat/SolvAttr.h | 1 + 4 files changed, 12 insertions(+) diff --git a/zypp/Patch.cc b/zypp/Patch.cc index 63fccd9..858c24f 100644 --- a/zypp/Patch.cc +++ b/zypp/Patch.cc @@ -80,6 +80,10 @@ namespace zypp bool Patch::restartSuggested() const { return lookupBoolAttribute( sat::SolvAttr::restartSuggested ); } + bool Patch::reloginSuggested() const + { return lookupBoolAttribute( sat::SolvAttr::reloginSuggested ); } + + bool Patch::interactive() const { if ( rebootSuggested() diff --git a/zypp/Patch.h b/zypp/Patch.h index 9612ca7..ed38f9b 100644 --- a/zypp/Patch.h +++ b/zypp/Patch.h @@ -82,6 +82,12 @@ namespace zypp bool restartSuggested() const; /** + * Does the patch needs the user to relogin to take effect? + * relogin is suggested then + */ + bool reloginSuggested() const; + + /** * \short Information or warning to be displayed to the user */ std::string message( const Locale & lang_r = Locale() ) const; diff --git a/zypp/sat/SolvAttr.cc b/zypp/sat/SolvAttr.cc index 4cb09b7..188ecf4 100644 --- a/zypp/sat/SolvAttr.cc +++ b/zypp/sat/SolvAttr.cc @@ -74,6 +74,7 @@ namespace sat const SolvAttr SolvAttr::patchcategory ( SOLVABLE_PATCHCATEGORY ); const SolvAttr SolvAttr::rebootSuggested ( UPDATE_REBOOT ); const SolvAttr SolvAttr::restartSuggested ( UPDATE_RESTART ); + const SolvAttr SolvAttr::reloginSuggested ( UPDATE_RELOGIN ); const SolvAttr SolvAttr::message ( UPDATE_MESSAGE ); const SolvAttr SolvAttr::updateCollectionName ( UPDATE_COLLECTION_NAME ); const SolvAttr SolvAttr::updateCollectionEvr ( UPDATE_COLLECTION_EVR ); diff --git a/zypp/sat/SolvAttr.h b/zypp/sat/SolvAttr.h index 0c1062e..d0ffaa2 100644 --- a/zypp/sat/SolvAttr.h +++ b/zypp/sat/SolvAttr.h @@ -95,6 +95,7 @@ namespace sat static const SolvAttr patchcategory; static const SolvAttr rebootSuggested; static const SolvAttr restartSuggested; + static const SolvAttr reloginSuggested; static const SolvAttr message; static const SolvAttr updateCollectionName; static const SolvAttr updateCollectionEvr; -- 2.7.4