ConfigDialog.py 2.31 KB
# -*- coding: utf-8 -*-
# generated by wxGlade 0.6.3 on Tue Sep 27 14:54:14 2011

import wx

import i18n
_ = i18n.language.ugettext #use ugettext instead of getttext to avoid unicode errors

# begin wxGlade: dependencies
# end wxGlade

# begin wxGlade: extracode

# end wxGlade

class ConfigDialog(wx.Dialog):
    def __init__(self, *args, **kwds):
        # begin wxGlade: ConfigDialog.__init__
        kwds["style"] = wx.DEFAULT_DIALOG_STYLE
        wx.Dialog.__init__(self, *args, **kwds)
        self.label_2 = wx.StaticText(self, -1, _("login")+":")
        self.login_ctrl = wx.TextCtrl(self, -1, "")
        self.label_6 = wx.StaticText(self, -1, _("password")+":")
        self.passwd_ctrl = wx.TextCtrl(self, -1, "", style=wx.TE_PASSWORD)
        self.label_5 = wx.StaticText(self, -1, _("extensions")+":")
        self.exts_ctrl = wx.TextCtrl(self, -1, "", size=(250,30))
        self.button_2 = wx.Button(self, wx.ID_OK, _("OK"))

        self.__set_properties()
        self.__do_layout()
        # end wxGlade

    def __set_properties(self):
        # begin wxGlade: ConfigDialog.__set_properties
        self.SetTitle(_("Directory configuration"))
        self.label_2.SetToolTipString(_("Login supplied by system administrator"))
        self.label_6.SetToolTipString(_("Password supplied by system administrator"))
        self.label_5.SetToolTipString(_("List of space separated file extensions"))
        self.button_2.SetMinSize((85, 29))
        self.button_2.SetFocus()
        # end wxGlade

    def __do_layout(self):
        # begin wxGlade: ConfigDialog.__do_layout
        sizer_5 = wx.BoxSizer(wx.VERTICAL)
        grid_sizer_4 = wx.GridSizer(3, 2, 0, 0)
        grid_sizer_4.Add(self.label_2, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        grid_sizer_4.Add(self.login_ctrl, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        grid_sizer_4.Add(self.label_6, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        grid_sizer_4.Add(self.passwd_ctrl, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        grid_sizer_4.Add(self.label_5, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        grid_sizer_4.Add(self.exts_ctrl, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        sizer_5.Add(grid_sizer_4, 0, 0, 0)
        sizer_5.Add(self.button_2, 0, wx.ALIGN_CENTER_HORIZONTAL, 0)
        self.SetSizer(sizer_5)
        sizer_5.Fit(self)
        self.Layout()
        # end wxGlade

# end of class ConfigDialog