csvdump.py 文件源码

python
阅读 17 收藏 0 点赞 0 评论 0

项目:chirp_fork 作者: mach327 项目源码 文件源码
def make_file_ctl(self):
        self.w_fileframe = gtk.Frame("File")

        vbox = gtk.VBox(False, 2)
        vbox.set_border_width(2)

        hbox = gtk.HBox(False, 2)
        hbox.set_border_width(2)

        l = gtk.Label("File")
        l.show()
        hbox.pack_start(l, 0, , )

        self.w_filename = gtk.Entry()
        self.w_filename.connect("changed", self.file_changed)
        self.tips.set_tip(self.w_filename, "Path to CSV file")
        self.w_filename.show()
        hbox.pack_start(self.w_filename, 1, , )

        bb = StdButton("Browse")
        bb.connect("clicked", self.pick_file)
        bb.show()
        hbox.pack_start(bb, 0, , )

        hbox.show()
        vbox.pack_start(hbox, 0, , )

        hbox = gtk.HBox(True, 2)
        hbox.set_border_width(2)

        def export_handler(x):
            return self.fn_eport(self.w_filename.get_text())
        self.w_export = StdButton("Export")
        self.w_export.set_sensitive(False)
        self.w_export.connect("clicked", export_handler)
        self.tips.set_tip(self.w_export,
                          "Export radio memories to CSV file")
        self.w_export.show()
        hbox.pack_start(self.w_export, 0, , )

        def import_handler(x):
            return self.fn_iport(self.w_filename.get_text())
        self.w_import = StdButton("Import")
        self.w_import.set_sensitive(False)
        self.w_import.connect("clicked", import_handler)
        self.tips.set_tip(self.w_import,
                          "Import radio memories from CSV file")
        self.w_import.show()
        hbox.pack_start(self.w_import, 0, , )

        hbox.show()
        vbox.pack_start(hbox, 0, , )

        vbox.show()
        self.w_fileframe.add(vbox)
        self.w_fileframe.show()

        return self.w_fileframe
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号