xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Ian Campbell <ian.campbell@citrix.com>
To: xen-devel@lists.xen.org
Cc: keir@xen.org, ian.jackson@eu.citrix.com,
	Ian Campbell <ian.campbell@citrix.com>
Subject: [PATCH 4/9] tools: delete xsview
Date: Wed, 31 Jul 2013 16:15:52 +0100	[thread overview]
Message-ID: <1375283757-19465-4-git-send-email-ian.campbell@citrix.com> (raw)
In-Reply-To: <1375283736.7382.100.camel@kazak.uk.xensource.com>

This was apparently a Qt xenstore viewer. It hasn't been touched since it was
first committed in 2007 and I can't beleive anyone is actually using even if
it still happens to work.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
---
 tools/misc/Makefile                 |    2 +-
 tools/misc/xsview                   |    9 --
 tools/python/setup.py               |    1 -
 tools/python/xen/xsview/main.py     |   10 --
 tools/python/xen/xsview/xsviewer.py |  168 -----------------------------------
 5 files changed, 1 insertions(+), 189 deletions(-)
 delete mode 100644 tools/misc/xsview
 delete mode 100644 tools/python/xen/xsview/__init__.py
 delete mode 100644 tools/python/xen/xsview/main.py
 delete mode 100644 tools/python/xen/xsview/xsviewer.py

diff --git a/tools/misc/Makefile b/tools/misc/Makefile
index 73b55dd..9c69e0d 100644
--- a/tools/misc/Makefile
+++ b/tools/misc/Makefile
@@ -22,7 +22,7 @@ INSTALL_BIN-y := xencons xencov_split
 INSTALL_BIN-$(CONFIG_X86) += xen-detect
 INSTALL_BIN := $(INSTALL_BIN-y)
 
-INSTALL_SBIN-y := xen-bugtool xen-python-path xenperf xsview xenpm xen-tmem-list-parse gtraceview \
+INSTALL_SBIN-y := xen-bugtool xen-python-path xenperf xenpm xen-tmem-list-parse gtraceview \
 	gtracestat xenlockprof xenwatchdogd xen-ringwatch xencov
 INSTALL_SBIN-$(CONFIG_X86) += xen-hvmctx xen-hvmcrash xen-lowmemd
 INSTALL_SBIN-$(CONFIG_MIGRATE) += xen-hptool
diff --git a/tools/misc/xsview b/tools/misc/xsview
deleted file mode 100644
index f926fe4..0000000
--- a/tools/misc/xsview
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/usr/bin/env python
-
-import sys
-
-from xen.xsview import main
-
-main.main(sys.argv)
-
-
diff --git a/tools/python/setup.py b/tools/python/setup.py
index 4f66564..8e584e6 100644
--- a/tools/python/setup.py
+++ b/tools/python/setup.py
@@ -133,7 +133,6 @@ setup(name            = 'xen',
       packages        = ['xen',
                          'xen.lowlevel',
                          'xen.sv',
-                         'xen.xsview',
                          ] + xend_packages,
       ext_package = "xen.lowlevel",
       ext_modules = modules
diff --git a/tools/python/xen/xsview/__init__.py b/tools/python/xen/xsview/__init__.py
deleted file mode 100644
index e69de29..0000000
diff --git a/tools/python/xen/xsview/main.py b/tools/python/xen/xsview/main.py
deleted file mode 100644
index b8d3b41..0000000
--- a/tools/python/xen/xsview/main.py
+++ /dev/null
@@ -1,10 +0,0 @@
-from xsviewer import *
-from qt import *
-
-def main(args):
-    app = QApplication(args)
-    mainwin = XSViewer(app)
-    mainwin.show()
-    app.connect(app, SIGNAL("lastWindowClosed()"),
-                app, SLOT("quit()"))
-    app.exec_loop()
diff --git a/tools/python/xen/xsview/xsviewer.py b/tools/python/xen/xsview/xsviewer.py
deleted file mode 100644
index 4dbaf98..0000000
--- a/tools/python/xen/xsview/xsviewer.py
+++ /dev/null
@@ -1,168 +0,0 @@
-from qt import *
-
-import xen.lowlevel.xs
-
-class XSViewer(QMainWindow):
-    
-    def __init__(self, app):
-        apply(QMainWindow.__init__, (self,))
-        
-        self.setCaption('XenStore Viewer')
-
-        self.new_node = QAction(self, 'New Node')
-        self.new_node.setText('New Node...')
-        self.connect(self.new_node, SIGNAL('activated()'),
-                     self.do_new_node)
-        
-        self.rm_node = QAction(self, 'Remove Node')
-        self.rm_node.setText('Remove Node')
-        self.connect(self.rm_node, SIGNAL('activated()'),
-                     self.do_rm_node)
-
-        self.refresh = QAction(self, 'Refresh')
-        self.refresh.setText('Refresh')
-        self.connect(self.refresh, SIGNAL('activated()'),
-                     self.do_refresh)
- 
-        self.file_menu = QPopupMenu(self)
-        self.new_node.addTo(self.file_menu)
-        self.rm_node.addTo(self.file_menu)
-        self.refresh.addTo(self.file_menu)
-
-
-        self.about = QAction(self, 'About')
-        self.about.setText('About...')
-        self.connect(self.about, SIGNAL('activated()'),
-                     self.do_about)
-
-        self.help_menu = QPopupMenu(self)
-        self.about.addTo(self.help_menu)
-
-        self.menubar = QMenuBar(self)
-        self.menubar.insertItem('&File', self.file_menu)
-        self.menubar.insertItem('&Help', self.help_menu)
-
-        self.vbox = QVBox(self)
-        self.setCentralWidget(self.vbox)
-
-        self.xs_tree = QListView(self.vbox)
-        self.xs_tree.addColumn('Key')
-        self.xs_tree.setRootIsDecorated(1)
-        self.xs_tree.connect(self.xs_tree, SIGNAL('selectionChanged(QListViewItem*)'), self.showValue)
-
-        self.info_box = QHBox(self.vbox)
-        self.info_box.setMargin(2)
-        self.info_box.setSpacing(2)
-        self.info_label = QLabel(self.info_box)
-        self.info_label.setText('Value')
-        self.info = QLineEdit(self.info_box)
-        self.setval = QPushButton(self.info_box)
-        self.setval.setText('Set')
-        self.setval.connect(self.setval, SIGNAL('clicked()'), self.setValue)
-
-        self.xs_handle = xen.lowlevel.xs.xs()
-
-        self.showtree()
-
-
-    def showtree(self):
-        xstransact = self.xs_handle.transaction_start()
-        self.walktree(xstransact, '/', '/', self.xs_tree)
-        self.xs_handle.transaction_end(xstransact)
-
-    def walktree(self, trans, node, subdir_prepend, parent_widget):
-
-        ents = self.xs_handle.ls(trans, node)
-        if ents == None:
-            return
-
-        for e in ents:
-            i = QListViewItem(parent_widget, e)
-            i.full_path = subdir_prepend + e
-            self.walktree(trans, i.full_path, i.full_path + '/', i)
-
-    
-    def showValue(self, item):
-        trans = self.xs_handle.transaction_start()
-        val = self.xs_handle.read(trans, item.full_path)
-        self.info.setText(val)
-        self.xs_handle.transaction_end(trans)
-
-
-    def setValue(self):
-        trans = self.xs_handle.transaction_start()
-        item = self.xs_tree.currentItem()
-        newval = str(self.info.text())
-
-        self.xs_handle.write(trans, item.full_path, newval)
-
-        self.xs_handle.transaction_end(trans)
-
-
-    def do_refresh(self):
-        self.xs_tree.clear()
-        self.info.clear()
-        self.showtree()
-
-    def do_new_node(self):
-        dia = QDialog(self)
-        dia.setCaption('Create new node')
-
-        vbox = QVBox(dia)
-
-        setting_hbox = QHBox(vbox)
-        
-        path_label = QLabel(setting_hbox)
-        path_label.setText('Node path')
-        path = QLineEdit(setting_hbox)
-        
-        value_label = QLabel(setting_hbox)
-        value_label.setText('Node value')
-        val = QLineEdit(setting_hbox)
-
-        button_hbox = QHBox(vbox)
-
-        set = QPushButton(button_hbox)
-        set.setText('Set')
-        self.connect(set, SIGNAL('clicked()'), dia, SLOT('accept()'))
-
-        cancel = QPushButton(button_hbox)
-        cancel.setText('Cancel')
-        self.connect(cancel, SIGNAL('clicked()'), dia, SLOT('reject()'))
-
-        setting_hbox.adjustSize()
-        button_hbox.adjustSize()
-        vbox.adjustSize()
-
-        if dia.exec_loop() == QDialog.Accepted:
-            trans = self.xs_handle.transaction_start()
-            self.xs_handle.write(trans, str(path.text()), str(val.text()))
-            
-            self.xs_handle.transaction_end(trans)
-
-            self.do_refresh()
-        
-        # nothing to set.
-
-    def do_rm_node(self):
-        trans = self.xs_handle.transaction_start()
-        item = self.xs_tree.currentItem()
-        newval = str(self.info.text())
-
-        self.xs_handle.rm(trans, item.full_path)
-
-        self.xs_handle.transaction_end(trans)
-
-        self.do_refresh()
-
-    def do_about(self):
-        about_dia = QMessageBox(self)
-        about_dia.setIcon(QMessageBox.Information)
-
-        about_dia.setCaption('About XenStore Viewer')
-        about_dia.setText('XenStore Viewer\n'
-                          'by Mark Williamson <mark.williamson@cl.cam.ac.uk>')
-
-        about_dia.exec_loop()
-        
-        
-- 
1.7.2.5

  parent reply	other threads:[~2013-07-31 15:15 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-31 15:15 [PATCH 0/9] tools: remove or disable old/useless/unused/unmainted stuff Ian Campbell
2013-07-31 15:15 ` [PATCH 1/9] tools: move xm and xend under tools python Ian Campbell
2013-08-07 15:03   ` Ian Jackson
2013-07-31 15:15 ` [PATCH 2/9] tools: make building xend configurable Ian Campbell
2013-08-07 15:04   ` Ian Jackson
2013-07-31 15:15 ` [PATCH 3/9] tools: remove in tree libaio Ian Campbell
2013-08-01  8:38   ` Egger, Christoph
2013-08-01 14:39     ` Ian Campbell
2013-08-07 15:06   ` Ian Jackson
2013-08-08  9:07     ` Ian Campbell
2013-08-20 14:28       ` Ian Campbell
2013-07-31 15:15 ` Ian Campbell [this message]
2013-08-07 15:06   ` [PATCH 4/9] tools: delete xsview Ian Jackson
2013-07-31 15:15 ` [PATCH 5/9] tools: remove miniterm Ian Campbell
2013-08-07 15:07   ` Ian Jackson
2013-07-31 15:15 ` [PATCH 6/9] tools: remove lomount Ian Campbell
2013-08-07 15:08   ` Ian Jackson
2013-07-31 15:15 ` [PATCH 7/9] .*ignore: remove some cruft Ian Campbell
2013-08-07 15:09   ` Ian Jackson
2013-07-31 15:15 ` [PATCH 8/9] tools: disable blktap1 build by default Ian Campbell
2013-08-07 15:13   ` Ian Jackson
2013-07-31 15:15 ` [PATCH 9/9] tools: drop 'sv' Ian Campbell
2013-08-07 15:13   ` Ian Jackson
2013-07-31 15:29 ` [PATCH 0/9] tools: remove or disable old/useless/unused/unmainted stuff Andrew Cooper
2013-07-31 15:35   ` Ian Campbell
2013-07-31 15:57     ` Andrew Cooper
2013-07-31 16:37 ` Andrew Cooper
2013-08-01  6:11   ` Matt Wilson
2013-08-20 15:03     ` Ian Campbell
2013-08-12 14:53 ` Fabio Fantoni

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1375283757-19465-4-git-send-email-ian.campbell@citrix.com \
    --to=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=keir@xen.org \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).