#!/usr/bin/env python
# -*- coding: utf-8 -*-
import wx
from library import i18n
from pnl_common import CommonPanel
_ = i18n.i18n()
class panel(CommonPanel):
""" Panel that represent a file db
"""
def __init__(self, parent):
"""create the db configuration panel for local dbs
"""
super(panel, self).__init__(parent)
parent = self
# ctrls creation
lbl_dsn = wx.StaticText(parent, -1, _("fac_lbl_dsn"))
tctrl_dsn = wx.TextCtrl(parent)
lbl_table = wx.StaticText(parent, -1, _("fac_lbl_table"))
tctrl_table = wx.TextCtrl(parent)
# ctrls layout
sz_file = wx.GridBagSizer()
flg = wx.ALIGN_LEFT | wx.ALIGN_CENTER_VERTICAL | wx.EXPAND | wx.ALL
sz_file.Add(lbl_dsn, (0,0), (1,1), flg, 5)
sz_file.Add(tctrl_dsn, (0,1), (1,1), flg, 5)
sz_file.Add(lbl_table, (1,0), (1,1), flg, 5)
sz_file.Add(tctrl_table, (1,1), (1,1), flg, 5)
self.SetSizerAndFit(sz_file)
self._lst_widgetd = (tctrl_dsn, tctrl_table)
|