quassel-bug-1031.patch
| src/qtui/chatscene.cpp | ||
|---|---|---|
| 799 | 799 |
chatView()->addActionsToMenu(&menu, pos); |
| 800 | 800 |
menu.addSeparator(); |
| 801 | 801 | |
| 802 |
if (isPosOverSelection(pos)) |
|
| 803 |
menu.addAction(SmallIcon("edit-copy"), tr("Copy Selection"),
|
|
| 804 |
this, SLOT(selectionToClipboard()), |
|
| 805 |
QKeySequence::Copy); |
|
| 806 | ||
| 807 | 802 |
// item-specific options (select link etc) |
| 808 | 803 |
ChatItem *item = chatItemAt(pos); |
| 809 | 804 |
if (item) |
| ... | ... | |
| 812 | 807 |
// no item -> default scene actions |
| 813 | 808 |
GraphicalUi::contextMenuActionProvider()->addActions(&menu, filter(), BufferId()); |
| 814 | 809 | |
| 810 |
// If we have text selected, insert the Copy Selection as first item |
|
| 811 |
if (isPosOverSelection(pos)) {
|
|
| 812 |
QAction *act = new Action(SmallIcon("edit-copy"), tr("Copy Selection"), &menu, this,
|
|
| 813 |
SLOT(selectionToClipboard()), QKeySequence::Copy); |
|
| 814 |
menu.insertAction(menu.actions().at(0), act); |
|
| 815 |
} |
|
| 816 | ||
| 815 | 817 |
if (QtUi::mainWindow()->menuBar()->isHidden()) |
| 816 | 818 |
menu.addAction(QtUi::actionCollection("General")->action("ToggleMenuBar"));
|
| 817 | 819 | |