def open_menu(self):
    item = self.watchFoldersTreeWidget.currentItem()
    if item:
        if item.data(0, QtCore.Qt.UserRole):
            menu = self.watch_items_menu()
            if menu:
                menu.exec_(Qt4Gui.QCursor.pos())
def open_menu(self):
    item = self.watchFoldersTreeWidget.currentItem()
    if item:
        if item.data(0, QtCore.Qt.UserRole):
            menu = self.watch_items_menu()
            if menu:
                menu.exec_(Qt4Gui.QCursor.pos())