예제 #1
0
 def __calc_walked_distance_window_with_direction(self):
     winsize, ok = QInputDialog.getInt(
         self, "Calculate the walked distance with direction",
         "Enter the window size", 30)
     if ok:
         v2 = self.object2d.create_value()
         v2.name = "Walked distance with direction in the previous {0} frames".format(
             winsize)
         _, v2._values = self.calc_walked_distance_with_direction(winsize)
예제 #2
0
 def input_int(self,
               msg,
               title='',
               default=0,
               min=-2147483647,
               max=2147483647):
     text, ok = QInputDialog.getInt(self,
                                    title,
                                    msg,
                                    value=default,
                                    min=min,
                                    max=max)
     if ok:
         return int(text)
     else:
         return None