Skip to content

Commit

Permalink
Merge bb50d26 into 10b251f
Browse files Browse the repository at this point in the history
  • Loading branch information
lslezak committed Mar 5, 2019
2 parents 10b251f + bb50d26 commit 6f24375
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 5 deletions.
18 changes: 14 additions & 4 deletions library/general/src/modules/Report.rb
Expand Up @@ -478,7 +478,9 @@ def Message(message_string)
Builtins.y2milestone(1, "%1", message_string) if @log_messages

if @display_messages
if Ops.greater_than(@timeout_messages, 0)
if Mode.commandline
CommandLine.Print(message_string)
elsif Ops.greater_than(@timeout_messages, 0)
Popup.TimedMessage(message_string, @timeout_messages)
else
Popup.Message(message_string)
Expand All @@ -499,7 +501,9 @@ def LongMessage(message_string, width: 60, height: 10)
Builtins.y2milestone(1, "%1", message_string) if @log_messages

if @display_messages
if Ops.greater_than(@timeout_messages, 0)
if Mode.commandline
CommandLine.Print(message_string)
elsif Ops.greater_than(@timeout_messages, 0)
Popup.TimedLongMessageGeometry(message_string, @timeout_messages, width, height)
else
Popup.LongMessageGeometry(message_string, width, height)
Expand All @@ -519,7 +523,11 @@ def ShowText(headline_string, message_string)
Builtins.y2milestone(1, "%1", message_string) if @log_errors

if @display_errors
if Ops.greater_than(@timeout_errors, 0)
if Mode.commandline
CommandLine.Print(headline_string)
CommandLine.Print("\n\n")
CommandLine.Print(message_string)
elsif Ops.greater_than(@timeout_errors, 0)
Popup.ShowTextTimed(headline_string, message_string, @timeout_errors)
else
Popup.ShowText(headline_string, message_string)
Expand Down Expand Up @@ -561,7 +569,9 @@ def LongWarning(warning_string, width: 60, height: 10)
Builtins.y2warning(1, "%1", warning_string) if @log_warnings

if @display_warnings
if Ops.greater_than(@timeout_warnings, 0)
if Mode.commandline
CommandLine.Print("Warning: #{error_string}")
elsif Ops.greater_than(@timeout_warnings, 0)
Popup.TimedLongWarningGeometry(warning_string, @timeout_warnings, width, height)
else
Popup.LongWarningGeometry(warning_string, width, height)
Expand Down
7 changes: 7 additions & 0 deletions package/yast2.changes
@@ -1,3 +1,10 @@
-------------------------------------------------------------------
Tue Mar 5 09:41:23 UTC 2019 - Ladislav Slezák <lslezak@suse.cz>

- Added command line support also for the other Report module
methods (related to bnc#1127685)
- 4.1.59

-------------------------------------------------------------------
Tue Mar 5 08:00:03 UTC 2019 - Ladislav Slezák <lslezak@suse.cz>

Expand Down
2 changes: 1 addition & 1 deletion package/yast2.spec
Expand Up @@ -17,7 +17,7 @@


Name: yast2
Version: 4.1.58
Version: 4.1.59
Release: 0
Summary: YaST2 - Main Package
License: GPL-2.0-only
Expand Down

0 comments on commit 6f24375

Please sign in to comment.