From 7b027848295930ad4dfaefca752aba5b5b4212e0 Mon Sep 17 00:00:00 2001 From: kollivier Date: Fri, 8 Sep 2017 14:21:31 -0700 Subject: [PATCH 01/15] SizedControls null sizer check for AUI support. --- wx/lib/sized_controls.py | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/wx/lib/sized_controls.py b/wx/lib/sized_controls.py index d0d53878..755ccd10 100644 --- a/wx/lib/sized_controls.py +++ b/wx/lib/sized_controls.py @@ -599,29 +599,33 @@ class SizedParent: """ def AddChild(self, child): """ - Add a child to sizer + This extends the default wx.Window behavior to also add the child + to its parent's sizer, if one exists, and set default properties. + When an entire UI layout is managed via Sizers, this helps reduce + the amount of sizer boilerplate code that needs to be written. :param `child`: child (window or another sizer) to be added to sizer. :type `child`: :class:`wx.Window` or :class:`wx.Sizer` """ - # Note: The wx.LogNull is used here to suppress a log message - # on wxMSW that happens because when AddChild is called the - # widget's hwnd hasn't been set yet, so the GetWindowRect that - # happens as a result of sizer.Add (in wxSizerItem::SetWindow) - # fails. A better fix would be to defer this code somehow - # until after the child widget is fully constructed. sizer = self.GetSizer() - nolog = wx.LogNull() - item = sizer.Add(child) - del nolog - item.SetUserData({"HGrow":0, "VGrow":0}) + if sizer: + # Note: The wx.LogNull is used here to suppress a log message + # on wxMSW that happens because when AddChild is called the + # widget's hwnd hasn't been set yet, so the GetWindowRect that + # happens as a result of sizer.Add (in wxSizerItem::SetWindow) + # fails. A better fix would be to defer this code somehow + # until after the child widget is fully constructed. + nolog = wx.LogNull() + item = sizer.Add(child) + del nolog + item.SetUserData({"HGrow": 0, "VGrow": 0}) - # Note: One problem is that the child class given to AddChild - # is the underlying wxWidgets control, not its Python subclass. So if - # you derive your own class, and override that class' GetDefaultBorder(), - # etc. methods, it will have no effect. - child.SetDefaultSizerProps() + # Note: One problem is that the child class given to AddChild + # is the underlying wxWidgets control, not its Python subclass. So if + # you derive your own class, and override that class' GetDefaultBorder(), + # etc. methods, it will have no effect. + child.SetDefaultSizerProps() def GetSizerType(self): """ From 3d29208ca2d2bb15caef65baf653c516ee4f147e Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Sat, 9 Sep 2017 16:59:30 -0700 Subject: [PATCH 02/15] Add changelog item for the SizedControls fix. --- CHANGES.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGES.rst b/CHANGES.rst index 3617f181..6dee9c7f 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -78,6 +78,10 @@ Changes in this release include the following: * Fix other instances of list.sort using old cmp-style ordering functions. (#508) +* Update SizedControls to do a sanity check on the parent's sizer, as GetSizer + can return None for SizedParent under certain circumstances, such as when + AUI reparents the control during pane movement. (#523) + From 70ddff2685ed0297ace34d855c77826991729dd3 Mon Sep 17 00:00:00 2001 From: HelioGuilherme66 Date: Sun, 10 Sep 2017 22:53:37 +0100 Subject: [PATCH 03/15] Adds Vagrant config for Fedora 26 --- vagrant/fedora-26/Vagrantfile | 28 ++++++++++++++++++++++++++++ vagrant/fedora-26/bootstrap.sh | 28 ++++++++++++++++++++++++++++ vagrant/fedora-26/repopatch.sh | 5 +++++ 3 files changed, 61 insertions(+) create mode 100644 vagrant/fedora-26/Vagrantfile create mode 100644 vagrant/fedora-26/bootstrap.sh create mode 100644 vagrant/fedora-26/repopatch.sh diff --git a/vagrant/fedora-26/Vagrantfile b/vagrant/fedora-26/Vagrantfile new file mode 100644 index 00000000..86c630b7 --- /dev/null +++ b/vagrant/fedora-26/Vagrantfile @@ -0,0 +1,28 @@ +# -*- mode: ruby -*- +# vi: set ft=ruby : + +Vagrant.configure("2") do |config| + + # Set which Vagrant "box" (base image) to use, and tell it how to set up the + # VM, packages to install, etc. + config.vm.box = "kilroy396/fedora26-h" + config.vm.box_version = "1.0.5" + config.vm.provision :shell, path: "repopatch.sh" # Replaces yum.repo.d with remote urls on image "kilroy396/fedora26-h" + config.vm.provision :shell, path: "bootstrap.sh" + + # Additional parameters for the VM + config.vm.provider "virtualbox" do |vb| + # vb.memory = 4096 + vb.memory = 2048 + # vb.cpus = 4 + vb.cpus = 2 + end + + # Share the Phoenix/dist folder so the VM can get the source tarball and has + # a place to put the build results. + config.vm.synced_folder "../../dist", "/home/vagrant/dist" + + # And share a folder with the build script + config.vm.synced_folder "../scripts", "/home/vagrant/scripts" + +end diff --git a/vagrant/fedora-26/bootstrap.sh b/vagrant/fedora-26/bootstrap.sh new file mode 100644 index 00000000..298c7472 --- /dev/null +++ b/vagrant/fedora-26/bootstrap.sh @@ -0,0 +1,28 @@ +#!/bin/bash + +# Set up and update package repos +dnf -y update +dnf -y install yum-utils + + +# Install necessary development tools, libs, etc. +dnf -y group install "Development Tools" +dnf -y install gcc-c++ + +dnf -y install gtk2 gtk2-devel gtk3 gtk3-devel \ + webkitgtk webkitgtk-devel webkitgtk3 webkitgtk3-devel \ + libjpeg-turbo-devel libpng-devel libtiff-devel \ + SDL SDL-devel gstreamer gstreamer-devel gstreamer-plugins-base-devel \ + freeglut freeglut-devel libnotify libnotify-devel libSM-devel + + +# Install all available Python packages and their dev packages +dnf -y install python python-tools python-devel python2-virtualenv +dnf -y install python3 python3-tools python3-devel + +# Set up virtual environments for each Python where the Phoenix builds will be +# done. set them to the vagrant user so the venv's can be updated by pip later. +mkdir venvs +virtualenv --python=python2.7 venvs/Py27 +python3.6 -m venv venvs/Py36 +chown -R vagrant:vagrant venvs diff --git a/vagrant/fedora-26/repopatch.sh b/vagrant/fedora-26/repopatch.sh new file mode 100644 index 00000000..80c473de --- /dev/null +++ b/vagrant/fedora-26/repopatch.sh @@ -0,0 +1,5 @@ +for i in `ls /etc/yum.repos.d/fedora.repo /etc/yum.repos.d/fedora-update*.repo` +do + sed -i "s/^#metalink=/metalink=/g" $i + sed -i "s/^baseurl=/#baseurl=/g" $i +done From e6f2593d992140ddb4b46352bde107439f360a93 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 14:58:39 -0700 Subject: [PATCH 04/15] Switch to fedora/26-cloud-base, remove repo patch and add Py35 --- vagrant/fedora-26/Vagrantfile | 10 +++------- vagrant/fedora-26/bootstrap.sh | 4 +++- vagrant/fedora-26/repopatch.sh | 5 ----- 3 files changed, 6 insertions(+), 13 deletions(-) delete mode 100644 vagrant/fedora-26/repopatch.sh diff --git a/vagrant/fedora-26/Vagrantfile b/vagrant/fedora-26/Vagrantfile index 86c630b7..a7062636 100644 --- a/vagrant/fedora-26/Vagrantfile +++ b/vagrant/fedora-26/Vagrantfile @@ -5,17 +5,13 @@ Vagrant.configure("2") do |config| # Set which Vagrant "box" (base image) to use, and tell it how to set up the # VM, packages to install, etc. - config.vm.box = "kilroy396/fedora26-h" - config.vm.box_version = "1.0.5" - config.vm.provision :shell, path: "repopatch.sh" # Replaces yum.repo.d with remote urls on image "kilroy396/fedora26-h" + config.vm.box = "fedora/26-cloud-base" config.vm.provision :shell, path: "bootstrap.sh" # Additional parameters for the VM config.vm.provider "virtualbox" do |vb| - # vb.memory = 4096 - vb.memory = 2048 - # vb.cpus = 4 - vb.cpus = 2 + vb.memory = 4096 + vb.cpus = 4 end # Share the Phoenix/dist folder so the VM can get the source tarball and has diff --git a/vagrant/fedora-26/bootstrap.sh b/vagrant/fedora-26/bootstrap.sh index 298c7472..2ab166cb 100644 --- a/vagrant/fedora-26/bootstrap.sh +++ b/vagrant/fedora-26/bootstrap.sh @@ -19,10 +19,12 @@ dnf -y install gtk2 gtk2-devel gtk3 gtk3-devel \ # Install all available Python packages and their dev packages dnf -y install python python-tools python-devel python2-virtualenv dnf -y install python3 python3-tools python3-devel +dnf -y install python35 # Set up virtual environments for each Python where the Phoenix builds will be -# done. set them to the vagrant user so the venv's can be updated by pip later. +# done. Set them to the vagrant user so the venv's can be updated by pip later. mkdir venvs virtualenv --python=python2.7 venvs/Py27 +python3.5 -m venv venvs/Py35 python3.6 -m venv venvs/Py36 chown -R vagrant:vagrant venvs diff --git a/vagrant/fedora-26/repopatch.sh b/vagrant/fedora-26/repopatch.sh deleted file mode 100644 index 80c473de..00000000 --- a/vagrant/fedora-26/repopatch.sh +++ /dev/null @@ -1,5 +0,0 @@ -for i in `ls /etc/yum.repos.d/fedora.repo /etc/yum.repos.d/fedora-update*.repo` -do - sed -i "s/^#metalink=/metalink=/g" $i - sed -i "s/^baseurl=/#baseurl=/g" $i -done From 8b0956fef51e4f8628363fb5860f33e427ad4ad2 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 14:59:05 -0700 Subject: [PATCH 05/15] Cleanup the F23 bootstrap a little --- vagrant/fedora-23/bootstrap.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/vagrant/fedora-23/bootstrap.sh b/vagrant/fedora-23/bootstrap.sh index 366c2133..89ca4af8 100644 --- a/vagrant/fedora-23/bootstrap.sh +++ b/vagrant/fedora-23/bootstrap.sh @@ -15,16 +15,16 @@ dnf -y install gtk2 gtk2-devel gtk3 gtk3-devel \ SDL SDL-devel gstreamer gstreamer-devel gstreamer-plugins-base-devel \ freeglut freeglut-devel libnotify libnotify-devel libSM-devel -dnf -y install python35 # Install all available Python packages and their dev packages dnf -y install python python-tools python-devel python-virtualenv dnf -y install python34 python34-tools python34-devel dnf -y install python3 python3-tools python3-devel +dnf -y install python35 # Set up virtual environments for each Python where the Phoenix builds will be -# done. set them to the vagrant user so the venv's can be updated by pip later. +# done. Set them to the vagrant user so the venv's can be updated by pip later. mkdir venvs virtualenv --python=python2.7 venvs/Py27 -pyvenv-3.4 venvs/Py34 -pyvenv-3.5 venvs/Py35 +python3.4 -m venv venvs/Py34 +python3.5 -m venv venvs/Py35 chown -R vagrant:vagrant venvs From ab0a816bb59c562962b9cc5fcb0c36ab927c872d Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 14:59:32 -0700 Subject: [PATCH 06/15] Make the build script a little easier to understand --- vagrant/scripts/build.sh | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/vagrant/scripts/build.sh b/vagrant/scripts/build.sh index e77105c0..ea9ae9ff 100755 --- a/vagrant/scripts/build.sh +++ b/vagrant/scripts/build.sh @@ -14,11 +14,15 @@ if [ "$NAME" == "" ]; then exit 1 fi -PYVER=$2 -if [ "$PYVER" == "" ]; then - PYVER=all +# This is the name of the virtual environment to be built. They should all be +# named like Py27, Py35, etc. If "all" is given then all the environments in +# ~/venvs will be used for a build. +PYENV=$2 +if [ "$PYENV" == "" ]; then + PYENV=all fi +# Either "gtk2", "gtk3" or "all" PORT=$3 if [ "$PORT" == "" ]; then PORT=all @@ -84,7 +88,7 @@ function do_build { # Do a build for each Python virtual environment in ~/venvs for VENV in ~/venvs/*; do - if [ $PYVER = all -o $PYVER = $(basename $VENV) ]; then + if [ $PYENV = all -o $PYENV = $(basename $VENV) ]; then # build a package for GTK2? if [ $PORT = all -o $PORT = gtk2 ]; then do_build $VENV gtk2 --gtk2 From 289bd592aaad6ad19b557f441989b7f3cf2ef042 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 15:00:46 -0700 Subject: [PATCH 07/15] Drop F24 --- CHANGES.rst | 4 ++++ vagrant/fedora-24/Vagrantfile | 24 ------------------------ vagrant/fedora-24/bootstrap.sh | 30 ------------------------------ 3 files changed, 4 insertions(+), 54 deletions(-) delete mode 100644 vagrant/fedora-24/Vagrantfile delete mode 100644 vagrant/fedora-24/bootstrap.sh diff --git a/CHANGES.rst b/CHANGES.rst index 6dee9c7f..08fc6369 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -82,6 +82,10 @@ Changes in this release include the following: can return None for SizedParent under certain circumstances, such as when AUI reparents the control during pane movement. (#523) +* Added Vagrant configs for Fedora 23 and Fedora 26, and dropped Fedora 24. + Wheels built on F23 can also be used on F24 and F25, and F26 adds Python 3.6 + support. + diff --git a/vagrant/fedora-24/Vagrantfile b/vagrant/fedora-24/Vagrantfile deleted file mode 100644 index 05e7c702..00000000 --- a/vagrant/fedora-24/Vagrantfile +++ /dev/null @@ -1,24 +0,0 @@ -# -*- mode: ruby -*- -# vi: set ft=ruby : - -Vagrant.configure("2") do |config| - - # Set which Vagrant "box" (base image) to use, and tell it how to set up the - # VM, packages to install, etc. - config.vm.box = "fedora/24-cloud-base" - config.vm.provision :shell, path: "bootstrap.sh" - - # Additional parameters for the VM - config.vm.provider "virtualbox" do |vb| - vb.memory = 4096 - vb.cpus = 4 - end - - # Share the Phoenix/dist folder so the VM can get the source tarball and has - # a place to put the build results. - config.vm.synced_folder "../../dist", "/home/vagrant/dist" - - # And share a folder with the build script - config.vm.synced_folder "../scripts", "/home/vagrant/scripts" - -end diff --git a/vagrant/fedora-24/bootstrap.sh b/vagrant/fedora-24/bootstrap.sh deleted file mode 100644 index 6a5352a6..00000000 --- a/vagrant/fedora-24/bootstrap.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/bash - -# Set up and update package repos -dnf -y update -dnf -y install yum-utils - - -# Install necessary development tools, libs, etc. -dnf -y group install "Development Tools" -dnf -y install gcc-c++ - -dnf -y install gtk2 gtk2-devel gtk3 gtk3-devel \ - webkitgtk webkitgtk-devel webkitgtk3 webkitgtk3-devel \ - libjpeg-turbo-devel libpng-devel libtiff-devel \ - SDL SDL-devel gstreamer gstreamer-devel gstreamer-plugins-base-devel \ - freeglut freeglut-devel libnotify libnotify-devel libSM-devel - - -# Install all available Python packages and their dev packages -dnf -y install python python-tools python-devel python2-virtualenv -#dnf -y install python34 python34-tools python34-devel -dnf -y install python3 python3-tools python3-devel - -# Set up virtual environments for each Python where the Phoenix builds will be -# done. set them to the vagrant user so the venv's can be updated by pip later. -mkdir venvs -virtualenv --python=python2.7 venvs/Py27 -#pyvenv-3.4 venvs/Py34 -pyvenv-3.5 venvs/Py35 -chown -R vagrant:vagrant venvs From d27d876037377672fa3c218f2c444014a1059ae2 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 15:08:17 -0700 Subject: [PATCH 08/15] Wording tweaks --- vagrant/README.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vagrant/README.rst b/vagrant/README.rst index 00c55e81..0c4d321a 100644 --- a/vagrant/README.rst +++ b/vagrant/README.rst @@ -57,7 +57,7 @@ example:: Please note that currently this will do up to 6 complete builds, one for each supported version of Python on that distro, for both gtk2 and gtk3. Additional parameters can be passed to the ``build.sh`` script to narrow the build down to -a specific Python version or port. See ``build.sh`` for details. +a specific Python version or port. See ``scripts/build.sh`` for details. The wheel file(s) generated by the build will be placed in subfolders of ``{PhoenixRoot}/dist/linux``. From a383d044646b9d6322240e98e6ade66351f2bd07 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 15:16:53 -0700 Subject: [PATCH 09/15] Drop F24 and add F26 in build.py --- build.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.py b/build.py index 0d061ab6..ad142e2a 100755 --- a/build.py +++ b/build.py @@ -1461,7 +1461,7 @@ def cmd_build_vagrant(options, args): VMs = [ 'centos-7', 'debian-8', 'fedora-23', - 'fedora-24', + 'fedora-26', 'ubuntu-14.04', 'ubuntu-16.04', ] From f92904a8bdac5d1b1f474849014c349f71f2b1ba Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 15:18:30 -0700 Subject: [PATCH 10/15] Phoenix --> wxPython4 and some additional info --- vagrant/README.rst | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/vagrant/README.rst b/vagrant/README.rst index 0c4d321a..1333584a 100644 --- a/vagrant/README.rst +++ b/vagrant/README.rst @@ -1,18 +1,19 @@ -Phoenix builds on various Linux distros with Vagrant -==================================================== +wxPython 4 builds on various Linux distros with Vagrant +======================================================= Vagrant (https://www.vagrantup.com/) is a tool that enables creating and using automated, relatively lightweight virtual environments. Vagrant and the Vagrant community provide several base images that are essentially simplistic bare-bones installs of various operating systems, that can be thought of as a bare canvas ready for provisioning with the needs of whatever applications -they will be used for. +they will be used for. The hosting platform can be Windows, Mac OSX, or Linux. -For Phoenix, this means that we can automate the creation and provisioning of +For wxPython, this means that we can automate the creation and provisioning of virtual Linux machines with all the packages installed that are needed for -building Phoenix. The subfodlers located in this folder contain the Vagrant -configurations and a bootstrap script for all of the Linux distros that we -currently support. +building wxPython 4. The each of the numbered subfolders located here contains +the Vagrant configuration and a bootstrap script for all of the Linux distros +that we currently support. As long as there is an existing vagrant "box" +available then adding support for new configurations is fairly simple. Setup From d86795d8846fac4ed0786019f1e69de655e3326b Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 15:38:49 -0700 Subject: [PATCH 11/15] Don't use the string module. Do use the new file dialog style flags. --- wx/lib/plot/plotcanvas.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/wx/lib/plot/plotcanvas.py b/wx/lib/plot/plotcanvas.py index e1b7c20b..12eaa0a0 100644 --- a/wx/lib/plot/plotcanvas.py +++ b/wx/lib/plot/plotcanvas.py @@ -14,7 +14,6 @@ __docformat__ = "restructuredtext en" # Standard Library import sys -import string as _string import time as _time # Third-Party @@ -342,7 +341,7 @@ class PlotCanvas(wx.Panel): "png": wx.BITMAP_TYPE_PNG, # Save a PNG file. } - fType = _string.lower(fileName[-3:]) + fType = fileName[-3:].lower() dlg1 = None while fType not in extensions: @@ -369,12 +368,12 @@ class PlotCanvas(wx.Panel): ".", "", wildcard_str, - wx.SAVE | wx.OVERWRITE_PROMPT, + wx.FD_SAVE | wx.FD_OVERWRITE_PROMPT, ) if dlg1.ShowModal() == wx.ID_OK: fileName = dlg1.GetPath() - fType = _string.lower(fileName[-3:]) + fType = fileName[-3:].lower() else: # exit without saving dlg1.Destroy() return False From c76880a6c3d278e01327f447efce2c15235e6d26 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 16:07:44 -0700 Subject: [PATCH 12/15] Ensure all window classes declare GetClassDefaultAttributes. Many do not actually have it, but the docs only declare it in wx.Window so we will miss the ones that really do have one unless we let sip know about them. --- etgtools/tweaker_tools.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/etgtools/tweaker_tools.py b/etgtools/tweaker_tools.py index a4ef4de6..ba93f0f8 100644 --- a/etgtools/tweaker_tools.py +++ b/etgtools/tweaker_tools.py @@ -229,7 +229,7 @@ def fixWindowClass(klass, hideVirtuals=True, ignoreProtected=True): """ Do common tweaks for a window class. """ - # NOTE: it may be okay to just do this for top-level windows + # NOTE: it may be okay to just do mustHaveApp for top-level windows # TODO: look into that possibility klass.mustHaveApp() @@ -261,6 +261,12 @@ def fixWindowClass(klass, hideVirtuals=True, ignoreProtected=True): removeVirtuals(klass) addWindowVirtuals(klass) + if not klass.findItem('GetClassDefaultAttributes'): + klass.addItem(extractors.WigCode("""\ + static wxVisualAttributes + GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL); + """)) + if not ignoreProtected: for item in klass.allItems(): if isinstance(item, extractors.MethodDef) and item.protection == 'protected': From 5544bbfee842a2cd8376d6f4a15bc35acdc1121a Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 16:48:40 -0700 Subject: [PATCH 13/15] Use integer division to find the item number. --- wx/lib/agw/ultimatelistctrl.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wx/lib/agw/ultimatelistctrl.py b/wx/lib/agw/ultimatelistctrl.py index 410d071e..fd6391ee 100644 --- a/wx/lib/agw/ultimatelistctrl.py +++ b/wx/lib/agw/ultimatelistctrl.py @@ -10147,7 +10147,7 @@ class UltimateListMainWindow(wx.ScrolledWindow): if self.InReportView(): if not self.HasAGWFlag(ULC_HAS_VARIABLE_ROW_HEIGHT): - current = y/self.GetLineHeight() + current = y // self.GetLineHeight() if current < count: newItem, flags = self.HitTestLine(current, x, y) if flags: From 839323a6a1fd29e4b41466434f06f0e54b471fc2 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 12 Sep 2017 17:10:56 -0700 Subject: [PATCH 14/15] Use bitwise OR --- wx/lib/agw/aui/framemanager.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wx/lib/agw/aui/framemanager.py b/wx/lib/agw/aui/framemanager.py index c47e35dc..874a7fc5 100644 --- a/wx/lib/agw/aui/framemanager.py +++ b/wx/lib/agw/aui/framemanager.py @@ -1283,7 +1283,7 @@ class AuiPaneInfo(object): def Restore(self): """ Is the reverse of :meth:`Maximize` and :meth:`Minimize`.""" - return self.SetFlag(self.optionMaximized or self.optionMinimized, False) + return self.SetFlag(self.optionMaximized | self.optionMinimized, False) def Fixed(self): From f882d21e8a4b5a528984e4630af275acaf7a7198 Mon Sep 17 00:00:00 2001 From: Scott Talbert Date: Tue, 12 Sep 2017 21:32:21 -0400 Subject: [PATCH 15/15] Fix wx.SearchCtrl.SetCancelBitmap() This addresses Trac ticket 17883. --- etg/srchctrl.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etg/srchctrl.py b/etg/srchctrl.py index 4e9667f5..b4950176 100644 --- a/etg/srchctrl.py +++ b/etg/srchctrl.py @@ -58,7 +58,7 @@ def run(): """\ #ifdef __WXMAC__ #else - self->SetSearchMenuBitmap(*bmp); + self->SetCancelBitmap(*bmp); #endif """)