| 42 | PartDocument::~PartDocument() = default; |
| 43 | |
| 44 | QWidget *PartDocument::createViewWidget(QWidget* /*parent*/) |
| 45 | { |
| 46 | Q_D(PartDocument); |
| 47 | |
| 48 | KParts::Part *part = Core::self()->partControllerInternal()->createPart(url(), d->preferredPart); |
| 49 | if( part ) |
| 50 | { |
| 51 | Core::self()->partController()->addPart(part); |
| 52 | QWidget *w = part->widget(); |
| 53 | d->partForView[w] = part; |
| 54 | return w; |
| 55 | } |
| 56 | return nullptr; |
| 57 | } |
| 58 | |
| 59 | KParts::Part *PartDocument::partForView(QWidget *view) const |
| 60 | { |
nothing calls this directly
no test coverage detected