MCPcopy Create free account
hub / github.com/KDE/kdevelop / setFileInfo

Method setFileInfo

plugins/patchreview/patchreviewtoolview.cpp:79–86  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77
78private:
79 void setFileInfo( QStandardItem *item, unsigned int hunksNum ) {
80 const auto url = item->index().data(VcsFileChangesModel::UrlRole).toUrl();
81 const QString path = ICore::self()->projectController()->prettyFileName(url, KDevelop::IProjectController::FormatPlain);
82 const QString newText = i18ncp( "%1: number of changed hunks, %2: file name",
83 "%2 (1 hunk)", "%2 (%1 hunks)", hunksNum,
84 path);
85 item->setText( newText );
86 }
87};
88
89PatchReviewToolView::PatchReviewToolView( QWidget* parent, PatchReviewPlugin* plugin )

Callers

nothing calls this directly

Calls 6

projectControllerMethod · 0.80
toUrlMethod · 0.45
dataMethod · 0.45
indexMethod · 0.45
prettyFileNameMethod · 0.45
setTextMethod · 0.45

Tested by

no test coverage detected