<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'># HG changeset patch<br># User K. Arvanitis <<a href="mailto:kosta@alumni.uvic.ca">kosta@alumni.uvic.ca</a>><br># Date 1422736039 28800<br># Parent 05767e5dabb45d0a99ca63df5705bc799e1858a3<br>[PATCH] Updated Memory Edit View #1<BR>This patch helps addres a concern some individuals were having<br>accessing the memory property page which contains some "extra"<br>memory settings which are not editable on the main treeview.<BR>This change modified the memory editor taskbar to include a button<br>which connects to the memory property page as well as adding a properties<br>menu item to the vie menu and memory editor context menu.<BR>Access to the memory property page should now be slightly improved and<br>more accessible to those people whom are not used to functioning with<br>a 2-button mouse button.<BR><br>Feature #2273<BR>diff -r 05767e5dabb4 chirpui/mainapp.py<br>--- a/chirpui/mainapp.py Thu Jan 29 07:24:01 2015 -0600<br>+++ b/chirpui/mainapp.py Sat Jan 31 12:30:12 2015 -0800<br>@@ -112,7 +112,8 @@<br> <br> for i in ["export", "close", "columns", "irbook", "irfinder",<br> "move_up", "move_dn", "exchange", "iradioreference",<br>- "cut", "copy", "paste", "delete", "viewdeveloper"]:<br>+ "cut", "copy", "paste", "delete", "viewdeveloper",<br>+ "properties"]:<br> set_action_sensitive(i, eset is not None)<br> <br> def ev_status(self, editorset, msg):<br>@@ -1420,7 +1421,7 @@<br> self.do_toggle_developer(_action)<br> elif action in ["cut", "copy", "paste", "delete",<br> "move_up", "move_dn", "exchange",<br>- "devshowraw", "devdiffraw"]:<br>+ "devshowraw", "devdiffraw", "properties"]:<br> self.get_current_editorset().get_current_editor().hotkey(_action)<br> elif action == "devdifftab":<br> self.do_diff_radio()<br>@@ -1461,6 +1462,8 @@<br> <menuitem action="move_up"/><br> <menuitem action="move_dn"/><br> <menuitem action="exchange"/><br>+ <separator/><br>+ <menuitem action="properties"/><br> </menu><br> <menu action="view"><br> <menuitem action="columns"/><br>@@ -1524,6 +1527,7 @@<br> ('move_up', None, _("Move _Up"), "<Control>Up", None, self.mh),<br> ('move_dn', None, _("Move Dow_n"), "<Control>Down", None, self.mh),<br> ('exchange', None, _("E_xchange"), "<Control><Shift>x", None, self.mh),<br>+ ('properties', None, _("P_roperties"), None, None, self.mh),<br> ('view', None, _("_View"), None, None, self.mh),<br> ('columns', None, _("Columns"), None, None, self.mh),<br> ('viewdeveloper', None, _("Developer"), None, None, self.mh),<br>diff -r 05767e5dabb4 chirpui/memdetail.py<br>--- a/chirpui/memdetail.py Thu Jan 29 07:24:01 2015 -0600<br>+++ b/chirpui/memdetail.py Sat Jan 31 12:30:12 2015 -0800<br>@@ -193,8 +193,6 @@<br> self.vbox.pack_start(sw, 1, 1, 1)<br> tab.show()<br> <br>- row = 0<br>-<br> def _err(name, msg):<br> try:<br> _img = self._editors[name][2]<br>@@ -210,6 +208,7 @@<br> self.set_response_sensitive(gtk.RESPONSE_OK,<br> True not in self._errors)<br> <br>+ row = 0<br> for name in self._order:<br> labeltxt, editorcls, data = self._elements[name]<br> <br>@@ -235,13 +234,10 @@<br> row += 1<br> self._order.append(name)<br> <br>- def _title(self):<br>- return _("Edit Memory #{num}").format(num=self._memory.number)<br>-<br> def __init__(self, features, memory, parent=None):<br> self._memory = memory<br> gtk.Dialog.__init__(self,<br>- title=self._title(),<br>+ title="Memory Properties",<br> flags=gtk.DIALOG_MODAL,<br> parent=parent,<br> buttons=(gtk.STOCK_OK, gtk.RESPONSE_OK,<br>@@ -337,8 +333,6 @@<br> return self._memory<br> <br> class MultiMemoryDetailEditor(MemoryDetailEditor):<br>- def _title(self):<br>- return _("Edit Multiple Memories")<br> <br> def __init__(self, features, memory, parent=None):<br> self._selections = dict()<br>diff -r 05767e5dabb4 chirpui/memedit.py<br>--- a/chirpui/memedit.py Thu Jan 29 07:24:01 2015 -0600<br>+++ b/chirpui/memedit.py Sat Jan 31 12:30:12 2015 -0800<br>@@ -795,7 +795,7 @@<br> self._show_raw(cur_pos)<br> elif action == "devdiffraw":<br> self._diff_raw(paths)<br>- elif action == "edit":<br>+ elif action == "properties":<br> job = common.RadioJob(self.edit_memory, "get_memory", cur_pos)<br> job.set_cb_args(selected)<br> self.rthread.submit(job)<br>@@ -828,7 +828,10 @@<br> menu_xml = """<br> <ui><br> <popup name="Menu"> <br>- <menuitem action="edit"/><br>+ <menuitem action="cut"/><br>+ <menuitem action="copy"/><br>+ <menuitem action="paste"/><br>+ <separator/><br> <menuitem action="insert_prev"/><br> <menuitem action="insert_next"/><br> <menu action="deletes"><br>@@ -840,9 +843,7 @@<br> <menuitem action="move_dn"/><br> <menuitem action="exchange"/><br> <separator/><br>- <menuitem action="cut"/><br>- <menuitem action="copy"/><br>- <menuitem action="paste"/><br>+ <menuitem action="properties"/><br> %s<br> </popup><br> </ui><br>@@ -854,7 +855,9 @@<br> istwo = len(paths) == 2<br> <br> actions = [<br>- ("edit", _("Edit")),<br>+ ("cut", _("Cut")),<br>+ ("copy", _("Copy")),<br>+ ("paste", _("Paste")),<br> ("insert_prev", _("Insert row above")),<br> ("insert_next", _("Insert row below")),<br> ("deletes", _("Delete")),<br>@@ -864,9 +867,7 @@<br> ("move_up", _("Move up")),<br> ("move_dn", _("Move down")),<br> ("exchange", _("Exchange memories")),<br>- ("cut", _("Cut")),<br>- ("copy", _("Copy")),<br>- ("paste", _("Paste")),<br>+ ("properties", _("P_roperties")),<br> ("devshowraw", _("Show Raw Memory")),<br> ("devdiffraw", _("Diff Raw Memories")),<br> ]<br>@@ -1153,7 +1154,7 @@<br> def make_controls(self, min, max):<br> hbox = gtk.HBox(False, 2)<br> <br>- lab = gtk.Label(_("Memory range:"))<br>+ lab = gtk.Label(_("Memory Range:"))<br> lab.show()<br> hbox.pack_start(lab, 0, 0, 0)<br> <br>@@ -1180,9 +1181,10 @@<br> hi.show()<br> hbox.pack_start(hi, 0, 0, 0)<br> <br>- refresh = gtk.Button(_("Go"))<br>+ refresh = gtk.Button(_("Refresh"))<br>+ refresh.set_relief(gtk.RELIEF_NONE)<br>+ refresh.connect("clicked", lambda x: self.prefill())<br> refresh.show()<br>- refresh.connect("clicked", lambda x: self.prefill())<br> hbox.pack_start(refresh, 0, 0, 0)<br> <br> def activate_go(widget):<br>@@ -1200,23 +1202,34 @@<br> <br> sep = gtk.VSeparator()<br> sep.show()<br>- sep.set_size_request(20, -1)<br>- hbox.pack_start(sep, 0, 0, 0)<br>+ hbox.pack_start(sep, 0, 0, 2)<br> <br>- showspecial = gtk.CheckButton(_("Special Channels"))<br>+ showspecial = gtk.ToggleButton(_("Special Channels"))<br>+ showspecial.set_relief(gtk.RELIEF_NONE)<br> showspecial.set_active(self.show_special)<br> showspecial.connect("toggled",<br> lambda x: self.set_show_special(x.get_active()))<br> showspecial.show()<br> hbox.pack_start(showspecial, 0, 0, 0)<br> <br>- showempty = gtk.CheckButton(_("Show Empty"))<br>+ showempty = gtk.ToggleButton(_("Show Empty"))<br>+ showempty.set_relief(gtk.RELIEF_NONE)<br> showempty.set_active(self.show_empty);<br> showempty.connect("toggled",<br> lambda x: self.set_show_empty(x.get_active()))<br> showempty.show()<br> hbox.pack_start(showempty, 0, 0, 0)<br> <br>+ sep = gtk.VSeparator()<br>+ sep.show()<br>+ hbox.pack_start(sep, 0, 0, 2)<br>+<br>+ props = gtk.Button(_("Properties"))<br>+ props.set_relief(gtk.RELIEF_NONE)<br>+ props.connect("clicked", lambda x: self.hotkey(gtk.Action("properties", "", "", 0)))<br>+ props.show()<br>+ hbox.pack_start(props, 0, 0, 0)<br>+<br> hbox.show()<br> <br> return hbox<br> <BR>                                            </div></body>
</html>