예제 #1
0
파일: exploits.py 프로젝트: Wuodan/inguma
    def on_treeview_button_press_event(self, treeview, event):
        if event.button == 3:
            x = int(event.x)
            y = int(event.y)
            time = event.time
            pthinfo = treeview.get_path_at_pos(x, y)
            if pthinfo is not None:
                path, col, cellx, celly = pthinfo
                treeview.grab_focus()
                treeview.set_cursor(path, col, 0)

                #print "Right Clicked!"
                treeiter = self.liststore.get_iter(path)
                exploit_path = self.liststore.get_value(treeiter, 1)

                exploit = 'data/exploits/' + exploit_path
                os.chmod(exploit, 0644)
                if self.config.HAS_SOURCEVIEW:
                    import lib.ui.editor as editor
                    editor.main(exploit)
            return True
예제 #2
0
    def on_treeview_button_press_event(self, treeview, event):
        if event.button == 3:
            x = int(event.x)
            y = int(event.y)
            time = event.time
            pthinfo = treeview.get_path_at_pos(x, y)
            if pthinfo is not None:
                path, col, cellx, celly = pthinfo
                treeview.grab_focus()
                treeview.set_cursor( path, col, 0)

                #print "Right Clicked!"
                treeiter = self.liststore.get_iter(path)
                exploit_path = self.liststore.get_value(treeiter ,1)

                exploit = 'data/exploits/' + exploit_path
                os.chmod(exploit, 0644)
                if self.config.HAS_SOURCEVIEW:
                    import lib.ui.editor as editor
                    editor.main(exploit)
            return True
예제 #3
0
    def loadEditor(self, widget):
        """ Loads module editor """

        import lib.ui.editor as editor
        editor.main()