Proper localization of AppController

This commit is contained in:
tamasmeszaros
2018-07-02 16:15:21 +02:00
parent 4f27f6c6dc
commit 478dd2a93f
6 changed files with 140 additions and 115 deletions

View File

@@ -3,6 +3,7 @@
#include <string>
#include <functional>
#include "Strings.hpp"
namespace Slic3r {
@@ -42,13 +43,13 @@ public:
}
/// Message shown on the next status update.
virtual void message(const std::string&) = 0;
virtual void message(const string&) = 0;
/// Title of the operaton.
virtual void title(const std::string&) = 0;
virtual void title(const string&) = 0;
/// Formatted message for the next status update. Works just like sprinf.
virtual void message_fmt(const std::string& fmt, ...);
virtual void message_fmt(const string& fmt, ...);
/// Set up a cancel callback for the operation if feasible.
inline void on_cancel(CancelFn func) { cancelfunc_ = func; }
@@ -60,7 +61,7 @@ public:
virtual void cancel() { cancelfunc_(); }
/// Convinience function to call message and status update in one function.
void update(float st, const std::string& msg) {
void update(float st, const string& msg) {
message(msg); state(st);
}
};