124 |
124 |
125 if link.isEmpty() or not link.isValid(): |
125 if link.isEmpty() or not link.isValid(): |
126 return |
126 return |
127 |
127 |
128 menu = QMenu() |
128 menu = QMenu() |
129 curTab = menu.addAction(self.trUtf8("Open Link")) |
129 curTab = menu.addAction(self.tr("Open Link")) |
130 newTab = menu.addAction(self.trUtf8("Open Link in New Tab")) |
130 newTab = menu.addAction(self.tr("Open Link in New Tab")) |
131 menu.move(evt.globalPos()) |
131 menu.move(evt.globalPos()) |
132 act = menu.exec_() |
132 act = menu.exec_() |
133 if act == curTab: |
133 if act == curTab: |
134 self.linkActivated.emit(link) |
134 self.linkActivated.emit(link) |
135 elif act == newTab: |
135 elif act == newTab: |