

def motion_notify_event(self, widget, event):
    button = self.kbdmouse_mask
    if event.is_hint:
        return
    else:
        (x, y, state) = (event.x_root, event.y_root, event.state)
    if (state & gtk.gdk.BUTTON1_MASK):
        button |= 1
    elif (state & gtk.gdk.BUTTON2_MASK):
        button |= 2
    elif (state & gtk.gdk.BUTTON3_MASK):
        button |= 4
    if ((button & 1) and (self.selected_child is not None)):
        bnch = self.selected_child
        subwin = bnch.subwin
        if (bnch.action == 'move'):
            x = int((subwin.x + (x - bnch.dx)))
            y = int((subwin.y + (y - bnch.dy)))
            self.move(subwin.frame, x, y)
        elif (bnch.action == 'resize'):
            wd = int((subwin.width + (x - bnch.dx)))
            ht = int((ht.height + (y - bnch.dy)))
            subwin.frame.set_size_request(wd, ht)
    return True

dataset/ETHPy150Open ejeschke/ginga/ginga/gtkw/GtkHelp.py MDIWidget.motion_notify_event/VarMisuse@241/293 `subwin`->`ht`