Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Marco Bubke
flatpak-qt-creator
Commits
b94821b6
Commit
b94821b6
authored
Jul 21, 2010
by
Roberto Raggi
Browse files
Get rid of the deprecated method Overview::setShowFullQualifiedNames().
parent
c969b6e1
Changes
4
Hide whitespace changes
Inline
Side-by-side
src/libs/cplusplus/Overview.cpp
View file @
b94821b6
...
...
@@ -44,7 +44,6 @@ Overview::Overview()
_showArgumentNames
(
false
),
_showReturnTypes
(
false
),
_showFunctionSignatures
(
true
),
_showFullyQualifiedNames
(
false
),
_showDefaultArguments
(
true
)
{
}
...
...
@@ -111,16 +110,6 @@ void Overview::setShowFunctionSignatures(bool showFunctionSignatures)
_showFunctionSignatures
=
showFunctionSignatures
;
}
bool
Overview
::
showFullyQualifiedNames
()
const
{
return
_showFullyQualifiedNames
;
}
void
Overview
::
setShowFullyQualifiedNamed
(
bool
showFullyQualifiedNames
)
{
_showFullyQualifiedNames
=
showFullyQualifiedNames
;
}
bool
Overview
::
showDefaultArguments
()
const
{
return
_showDefaultArguments
;
...
...
src/libs/cplusplus/Overview.h
View file @
b94821b6
...
...
@@ -53,9 +53,6 @@ public:
bool
showFunctionSignatures
()
const
;
void
setShowFunctionSignatures
(
bool
showFunctionSignatures
);
bool
showFullyQualifiedNames
()
const
;
void
setShowFullyQualifiedNamed
(
bool
showFullyQualifiedNames
);
bool
showDefaultArguments
()
const
;
void
setShowDefaultArguments
(
bool
showDefaultArguments
);
...
...
@@ -94,7 +91,6 @@ private:
bool
_showArgumentNames
:
1
;
bool
_showReturnTypes
:
1
;
bool
_showFunctionSignatures
:
1
;
bool
_showFullyQualifiedNames
:
1
;
bool
_showDefaultArguments
:
1
;
};
...
...
src/libs/cplusplus/TypePrettyPrinter.cpp
View file @
b94821b6
...
...
@@ -41,35 +41,6 @@
using
namespace
CPlusPlus
;
static
QString
fullyQualifiedName
(
Symbol
*
symbol
,
const
Overview
*
overview
)
{
QStringList
nestedNameSpecifier
;
for
(
Scope
*
scope
=
symbol
->
scope
();
scope
&&
scope
->
enclosingScope
();
scope
=
scope
->
enclosingScope
())
{
Symbol
*
owner
=
scope
->
owner
();
if
(
!
owner
)
{
qWarning
()
<<
"invalid scope."
;
// ### better message.
continue
;
}
if
(
!
owner
->
name
())
nestedNameSpecifier
.
prepend
(
QLatin1String
(
"$anonymous"
));
else
{
const
QString
name
=
overview
->
prettyName
(
owner
->
name
());
nestedNameSpecifier
.
prepend
(
name
);
}
}
nestedNameSpecifier
.
append
(
overview
->
prettyName
(
symbol
->
name
()));
return
nestedNameSpecifier
.
join
(
QLatin1String
(
"::"
));
}
TypePrettyPrinter
::
TypePrettyPrinter
(
const
Overview
*
overview
)
:
_overview
(
overview
)
,
_needsParens
(
false
)
...
...
@@ -171,20 +142,14 @@ void TypePrettyPrinter::visit(Namespace *type)
void
TypePrettyPrinter
::
visit
(
Class
*
classTy
)
{
if
(
overview
()
->
showFullyQualifiedNames
())
_text
.
prepend
(
fullyQualifiedName
(
classTy
,
overview
()));
else
_text
.
prepend
(
overview
()
->
prettyName
(
classTy
->
name
()));
_text
.
prepend
(
overview
()
->
prettyName
(
classTy
->
name
()));
prependCv
(
_fullySpecifiedType
);
}
void
TypePrettyPrinter
::
visit
(
Enum
*
type
)
{
if
(
overview
()
->
showFullyQualifiedNames
())
_text
.
prepend
(
fullyQualifiedName
(
type
,
overview
()));
else
_text
.
prepend
(
overview
()
->
prettyName
(
type
->
name
()));
_text
.
prepend
(
overview
()
->
prettyName
(
type
->
name
()));
prependCv
(
_fullySpecifiedType
);
}
...
...
src/plugins/cppeditor/cpphoverhandler.cpp
View file @
b94821b6
...
...
@@ -304,7 +304,6 @@ void CppHoverHandler::handleLookupItemMatch(const LookupItem &lookupItem,
Overview
overview
;
overview
.
setShowArgumentNames
(
true
);
overview
.
setShowReturnTypes
(
true
);
overview
.
setShowFullyQualifiedNamed
(
true
);
if
(
!
matchingDeclaration
&&
assignTooltip
)
{
m_toolTip
=
overview
.
prettyType
(
matchingType
,
QString
());
...
...
@@ -356,7 +355,6 @@ void CppHoverHandler::handleLookupItemMatch(const LookupItem &lookupItem,
overview
.
setShowArgumentNames
(
false
);
overview
.
setShowReturnTypes
(
false
);
overview
.
setShowFunctionSignatures
(
false
);
overview
.
setShowFullyQualifiedNamed
(
false
);
const
QString
&
simpleName
=
overview
.
prettyName
(
matchingDeclaration
->
name
());
overview
.
setShowFunctionSignatures
(
true
);
const
QString
&
specifierId
=
overview
.
prettyType
(
matchingType
,
simpleName
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment