[Kst] kdeextragear-2/kst/kst
Andrew Walker
arwalker at sumusltd.com
Fri Mar 18 18:33:31 CET 2005
CVS commit by arwalker:
Re-enable Edit...Copy functionality after changes to plotmimesource.cpp
CCMAIL: 96256 at bugs.kde.org
M +1 -14 kst.cpp 1.292
M +5 -0 kstviewwidget.cpp 1.72
--- kdeextragear-2/kst/kst/kst.cpp #1.291:1.292
@@ -1683,18 +1683,5 @@ void KstApp::slotCopy() {
KstViewWindow *vw = dynamic_cast<KstViewWindow*>(activeWindow());
if (vw) {
- KstTopLevelViewPtr tlv = vw->view();
- if (tlv) {
- QStringList plotList;
-
- for (KstViewObjectList::Iterator i = tlv->selectionList().begin();
- i != tlv->selectionList().end(); ++i) {
- plotList.append((*i)->tagName());
- }
-
- if (plotList.size() > 0) {
- PlotMimeSource *newplots = new PlotMimeSource(vw->caption(), plotList);
- QApplication::clipboard()->setData(newplots, QClipboard::Clipboard);
- }
- }
+ QApplication::clipboard()->setData(vw->view()->widget()->dragObject(), QClipboard::Clipboard);
}
}
--- kdeextragear-2/kst/kst/kstviewwidget.cpp #1.71:1.72
@@ -58,4 +58,9 @@ QDragObject *KstViewWidget::dragObject()
plots.append(_view->pressTarget()->tagName());
vol.append(_view->pressTarget());
+ } else {
+ for (size_t i=0; i<_view->children().size(); i++) {
+ plots.append(_view->children()[i]->tagName());
+ vol.append(_view->children()[i]);
+ }
}
} else {
More information about the Kst
mailing list