mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-02 17:45:28 +00:00
define strings preset
This commit is contained in:
parent
fb5a45316f
commit
2bb12d5339
2 changed files with 14 additions and 6 deletions
|
|
@ -29,6 +29,10 @@ class Open
|
||||||
'*.gmi' => null
|
'*.gmi' => null
|
||||||
];
|
];
|
||||||
|
|
||||||
|
public const DIALOG_TITLE = 'Open file';
|
||||||
|
public const DIALOG_BUTTON_CANCEL = 'Cancel';
|
||||||
|
public const DIALOG_BUTTON_OPEN = 'Open';
|
||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
File $file
|
File $file
|
||||||
) {
|
) {
|
||||||
|
|
@ -49,13 +53,13 @@ class Open
|
||||||
function()
|
function()
|
||||||
{
|
{
|
||||||
$dialog = new GtkFileChooserDialog(
|
$dialog = new GtkFileChooserDialog(
|
||||||
'Open file',
|
_($this::DIALOG_TITLE),
|
||||||
$this->file->menu->browser->gtk,
|
$this->file->menu->browser->gtk,
|
||||||
GtkFileChooserAction::OPEN,
|
GtkFileChooserAction::OPEN,
|
||||||
[
|
[
|
||||||
'Cancel',
|
_($this::DIALOG_BUTTON_CANCEL),
|
||||||
GtkResponseType::CANCEL,
|
GtkResponseType::CANCEL,
|
||||||
'Open',
|
_($this::DIALOG_BUTTON_OPEN),
|
||||||
GtkResponseType::OK
|
GtkResponseType::OK
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -22,6 +22,10 @@ class Save
|
||||||
// Defaults
|
// Defaults
|
||||||
public const LABEL = 'Save As..';
|
public const LABEL = 'Save As..';
|
||||||
|
|
||||||
|
public const DIALOG_TITLE = 'Save to file';
|
||||||
|
public const DIALOG_BUTTON_CANCEL = 'Cancel';
|
||||||
|
public const DIALOG_BUTTON_SAVE = 'Save';
|
||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
File $file
|
File $file
|
||||||
) {
|
) {
|
||||||
|
|
@ -42,13 +46,13 @@ class Save
|
||||||
function()
|
function()
|
||||||
{
|
{
|
||||||
$dialog = new GtkFileChooserDialog(
|
$dialog = new GtkFileChooserDialog(
|
||||||
'Save to file',
|
_($this::DIALOG_TITLE),
|
||||||
$this->file->menu->browser->gtk,
|
$this->file->menu->browser->gtk,
|
||||||
GtkFileChooserAction::SAVE,
|
GtkFileChooserAction::SAVE,
|
||||||
[
|
[
|
||||||
'Cancel',
|
_($this::DIALOG_BUTTON_CANCEL),
|
||||||
GtkResponseType::CANCEL,
|
GtkResponseType::CANCEL,
|
||||||
'Save',
|
_($this::DIALOG_BUTTON_SAVE),
|
||||||
GtkResponseType::APPLY
|
GtkResponseType::APPLY
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue