5 |
# This program is free software under the GPL (>=v2) |
# This program is free software under the GPL (>=v2) |
6 |
# Read the file COPYING coming with Thuban for details. |
# Read the file COPYING coming with Thuban for details. |
7 |
|
|
8 |
|
import sys |
9 |
|
|
10 |
from Thuban import _ |
from Thuban import _ |
11 |
|
|
12 |
from wxPython.wx import * |
from wxPython.wx import * |
314 |
self.numGroupsChanging = False |
self.numGroupsChanging = False |
315 |
self.steppingChanging = False |
self.steppingChanging = False |
316 |
|
|
317 |
self.numGroupsCtrl.SetRange(1, 100) |
self.numGroupsCtrl.SetRange(1, sys.maxint) |
318 |
|
|
319 |
self.numGroupsCtrl.SetValue(1) |
self.numGroupsCtrl.SetValue(1) |
320 |
self.stepCtrl.SetValue("1") |
self.stepCtrl.SetValue("1") |
364 |
self.numGroupsCtrl.Enable(on) |
self.numGroupsCtrl.Enable(on) |
365 |
self.stepCtrl.Enable(on) |
self.stepCtrl.Enable(on) |
366 |
|
|
|
if on: |
|
|
self.numGroupsCtrl.SetRange(1, abs(max - min) / 0.001) |
|
|
|
|
367 |
ngroups = self.GetNumGroups() |
ngroups = self.GetNumGroups() |
368 |
|
|
369 |
if ngroups is not None \ |
if ngroups is not None \ |
394 |
min = self.GetMin() |
min = self.GetMin() |
395 |
max = self.GetMax() |
max = self.GetMax() |
396 |
|
|
|
if ngroups >= self.numGroupsCtrl.GetMax(): |
|
|
self.numGroupsCtrl.SetRange(1, ngroups + 1) |
|
|
|
|
397 |
if ngroups is not None \ |
if ngroups is not None \ |
398 |
and min is not None \ |
and min is not None \ |
399 |
and max is not None \ |
and max is not None \ |