Пример #1
0
    def __on_merge(self, action):
        tab = PMApp().main_window.get_tab('PropertyTab')

        if self.active_diff:
            tab.remove_notify_for(self.active_diff, self.__diff_editing)
            self.active_diff = None

        if not self.active_layer or not self.active_packets:
            return

        log.debug("Merging %d packets" % len(self.active_packets))

        self.active_diff = backend.MetaPacket(self.active_layer())
        self.session.set_active_packet(self.active_diff)

        # Now we should connect the property tree signals to our
        # but we should check if the packet edited is our or not
        # because the property manages the edit phase of multiple
        # packets in multiple changes.

        tab.register_notify_for(self.active_diff, self.__diff_editing)
Пример #2
0
    def __on_merge(self, action):
        tab = PMApp().main_window.get_tab('PropertyTab')

        if self.active_diff:
            tab.remove_notify_for(self.active_diff, self.__diff_editing)
            self.active_diff = None

        if not self.active_layer or not self.active_packets:
            return

        log.debug("Merging %d packets" % len(self.active_packets))

        self.active_diff = backend.MetaPacket(self.active_layer())
        self.session.set_active_packet(self.active_diff)

        # Now we should connect the property tree signals to our
        # but we should check if the packet edited is our or not
        # because the property manages the edit phase of multiple
        # packets in multiple changes.

        tab.register_notify_for(self.active_diff, self.__diff_editing)