dialogs/ArrayTypeDialog.py
branchpython3
changeset 3750 f62625418bff
parent 3303 0ffb41625592
equal deleted inserted replaced
3749:fda6c1a37662 3750:f62625418bff
    20 # You should have received a copy of the GNU General Public License
    20 # You should have received a copy of the GNU General Public License
    21 # along with this program; if not, write to the Free Software
    21 # along with this program; if not, write to the Free Software
    22 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
    22 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
    23 
    23 
    24 
    24 
    25 from __future__ import absolute_import
    25 
    26 import re
    26 import re
    27 
    27 
    28 import wx
    28 import wx
    29 
    29 
    30 from controls import CustomEditableListBox
    30 from controls import CustomEditableListBox
    82         for datatype in datatypes:
    82         for datatype in datatypes:
    83             self.BaseType.Append(datatype)
    83             self.BaseType.Append(datatype)
    84 
    84 
    85         if isinstance(infos, tuple) and infos[0] == "array":
    85         if isinstance(infos, tuple) and infos[0] == "array":
    86             self.BaseType.SetStringSelection(infos[1])
    86             self.BaseType.SetStringSelection(infos[1])
    87             self.Dimensions.SetStrings(map("..".join, infos[2]))
    87             self.Dimensions.SetStrings(list(map("..".join, infos[2])))
    88         elif infos in datatypes:
    88         elif infos in datatypes:
    89             self.BaseType.SetStringSelection(infos)
    89             self.BaseType.SetStringSelection(infos)
    90 
    90 
    91         self.BaseType.SetFocus()
    91         self.BaseType.SetFocus()
    92         self.Fit()
    92         self.Fit()