Module: Yast::SambaServerWizardsInclude
- Defined in:
- ../../src/include/samba-server/wizards.rb
Instance Method Summary (collapse)
- - (Object) initialize_samba_server_wizards(include_target)
-
- (Object) MainSequence
Main workflow of the samba-server configuration.
-
- (Object) SambaServerAutoSequence
Whole configuration of samba-server but without reading and writing.
-
- (Object) SambaServerSequence
Whole configuration of samba-server.
Instance Method Details
- (Object) initialize_samba_server_wizards(include_target)
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File '../../src/include/samba-server/wizards.rb', line 30 def initialize_samba_server_wizards(include_target) Yast.import "UI" textdomain "samba-server" Yast.import "Sequencer" Yast.import "Wizard" Yast.import "Label" Yast.import "Mode" Yast.import "SambaServer" Yast.include include_target, "samba-server/complex.rb" Yast.include include_target, "samba-server/dialogs.rb" end |
- (Object) MainSequence
Main workflow of the samba-server configuration
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 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 |
# File '../../src/include/samba-server/wizards.rb', line 48 def MainSequence aliases = { "inst_step1" => lambda { Installation_Step1() }, "inst_step2" => lambda { Installation_Step2() }, "conf_tab" => lambda { Installation_Conf_Tab() }, "share_edit" => lambda { EditShareDialog() }, "share_add" => lambda { AddShareDialog() }, "passdb_edit" => lambda { PassdbDialog() }, "global_settings" => lambda { GlobalSettingsDialog() }, "ensure_root_account" => lambda { EnsureRootAccountDialog() }, "ask_join_domain" => lambda { AskJoinDomainDialog() } } sequence = { "ws_start" => "inst_step1", "inst_step1" => { :cancel => :cancel, :abort => :abort, :next => "inst_step2" }, "inst_step2" => { :back => "inst_step1", :cancel => :cancel, :abort => :abort, :next => "conf_tab" }, "conf_tab" => { :cancel => :cancel, :abort => :abort, :add => "share_add", :edit => "share_edit", :passdb => "passdb_edit", :global_settings => "global_settings", :next => "ask_join_domain" }, "ask_join_domain" => { :cancel => "conf_tab", :error => "conf_tab", :skip => :finish, :abort => :abort, :ok => "ensure_root_account" }, "ensure_root_account" => { :cancel => "conf_tab", :back => "conf_tab", :abort => :abort, :ok => :finish }, "global_settings" => { :cancel => :cancel, :abort => :abort, :next => "conf_tab" }, "share_edit" => { :cancel => :cancel, :abort => :abort, :next => "conf_tab" }, "share_add" => { :cancel => :cancel, :abort => :abort, :next => "conf_tab" }, "passdb_edit" => { :abort => :abort, :cancel => :cancel, :next => "conf_tab" } } # setup the abort function # SambaServer::AbortFunction = SambaServer::ServerReallyAbort; # run wizard only first time and not in autoyast if Mode.config || SambaServer.Configured Ops.set(sequence, "ws_start", "conf_tab") @return_tab = "shares" if !Mode.config end ret = Sequencer.Run(aliases, sequence) deep_copy(ret) end |
- (Object) SambaServerAutoSequence
Whole configuration of samba-server but without reading and writing. For use with autoinstallation.
165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 |
# File '../../src/include/samba-server/wizards.rb', line 165 def SambaServerAutoSequence # Initialization dialog caption caption = _("Samba Server Configuration") # Initialization dialog contents contents = Label(_("Initializing...")) Wizard.CreateDialog Wizard.SetContentsButtons( caption, contents, "", Label.BackButton, Label.NextButton ) ret = MainSequence() UI.CloseDialog deep_copy(ret) end |
- (Object) SambaServerSequence
Whole configuration of samba-server
135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 |
# File '../../src/include/samba-server/wizards.rb', line 135 def SambaServerSequence aliases = { "read" => [lambda { ReadDialog() }, true], "main" => lambda { MainSequence() }, "write" => [lambda { WriteDialog() }, true] } sequence = { "ws_start" => "read", "read" => { :abort => :abort, :next => "main" }, "main" => { :cancel => :abort, :abort => :abort, :finish => "write" }, "write" => { :abort => :abort, :next => :next } } Wizard.CreateDialog Wizard.SetDesktopTitleAndIcon("samba-server") ret = Sequencer.Run(aliases, sequence) UI.CloseDialog deep_copy(ret) end |