mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Do not copy strings when you don't need it.
This patch removed the use of copy-constructors on the QString to use the const-references. Even knowing that the QString is a refcounted class, let's not get that bad habit. Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3d83c48c49
commit
30770f5d85
2 changed files with 7 additions and 7 deletions
|
@ -12,15 +12,15 @@ public:
|
|||
void setCompleter(QCompleter *completer);
|
||||
QPair<int, int> getCursorTagPosition();
|
||||
void highlight();
|
||||
void setText(QString text);
|
||||
void setText(const QString& text);
|
||||
void clear();
|
||||
void setCursorPosition(int position);
|
||||
void wheelEvent(QWheelEvent *event);
|
||||
public
|
||||
slots:
|
||||
void reparse();
|
||||
void completionSelected(QString);
|
||||
void completionHighlighted(QString);
|
||||
void completionSelected(const QString& text);
|
||||
void completionHighlighted(const QString& text);
|
||||
|
||||
protected:
|
||||
void keyPressEvent(QKeyEvent *e);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue