File: RestoreTargetDialog.blp

package info (click to toggle)
deja-dup 49.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 9,332 kB
  • sloc: python: 1,218; sh: 161; xml: 48; makefile: 15
file content (73 lines) | stat: -rw-r--r-- 1,638 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
/* -*- Mode: Blueprint; indent-tabs-mode: nil; tab-width: 2 -*-
 *
 * SPDX-License-Identifier: CC-BY-SA-4.0
 * SPDX-FileCopyrightText: Michael Terry
 */

using Gtk 4.0;
using Adw 1;

template $RestoreTargetDialog: $ActionDialog {
  accept-label: _("_Restore");
  content-height: "250";
  content-width: "400";
  title: _("Restore to Where?");

  content: Adw.PreferencesGroup {
    Adw.ActionRow orig_row {
      activatable-widget: orig_radio;
      title: _("Restore files to their _original locations");
      use-underline: true;

      [prefix]
      CheckButton orig_radio {
        active: true;
        can-focus: false;
      }

      [suffix]
      $RestoreTargetWarningButton orig_warning {
        valign: "center";
        visible: "false";
      }
    }

    Adw.ActionRow folder_row {
      activatable-widget: folder_radio;
      title: _("Restore files to a _specific folder");
      use-underline: true;

      [prefix]
      CheckButton folder_radio {
        can-focus: false;
        group: orig_radio;
        toggled => $update_responses();
      }

      [suffix]
      $RestoreTargetWarningButton folder_warning {
        valign: "center";
        visible: "false";
      }
    }

    Adw.EntryRow folder_entry {
      activates-default: true;
      input-hints: no_spellcheck;
      title: _("_Folder");
      use-underline: true;
      sensitive: bind folder_radio.active;
      changed => $update_responses();

      [suffix]
      $FolderChooserButton open_button {
        valign: "center";
        file-selected => $handle_file_selected();

        styles [
          "flat",
        ]
      }
    }
  };
}