def get_selected_messages(self):
        """

        :rtype: list[SimulatorMessage]
        """
        return [item.model_item for item in self.selectedItems() if isinstance(item, MessageItem)]
def get_selected_messages ( self ) : return [ item . model_item for item in self . selectedItems ( ) if isinstance ( item , MessageItem ) ]
:rtype: list[SimulatorMessage]