Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Q
qt-creator
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Tobias Hunger
qt-creator
Commits
e8161ebd
Commit
e8161ebd
authored
16 years ago
by
con
Browse files
Options
Downloads
Patches
Plain Diff
Fixes: Copy from help sidebar doesn't work
parent
fcc271b6
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/plugins/coreplugin/icontext.h
+19
-0
19 additions, 0 deletions
src/plugins/coreplugin/icontext.h
src/plugins/help/helpplugin.cpp
+16
-0
16 additions, 0 deletions
src/plugins/help/helpplugin.cpp
src/plugins/help/helpplugin.h
+5
-4
5 additions, 4 deletions
src/plugins/help/helpplugin.h
with
40 additions
and
4 deletions
src/plugins/coreplugin/icontext.h
+
19
−
0
View file @
e8161ebd
...
...
@@ -51,6 +51,25 @@ public:
virtual
QString
contextHelpId
()
const
{
return
QString
();
}
};
class
BaseContext
:
public
Core
::
IContext
{
public:
BaseContext
(
QWidget
*
widget
,
const
QList
<
int
>
&
context
,
QObject
*
parent
=
0
)
:
Core
::
IContext
(
parent
),
m_widget
(
widget
),
m_context
(
context
)
{
}
QList
<
int
>
context
()
const
{
return
m_context
;
}
QWidget
*
widget
()
{
return
m_widget
;
}
private
:
QWidget
*
m_widget
;
QList
<
int
>
m_context
;
};
}
// namespace Core
#endif //ICONTEXT_H
This diff is collapsed.
Click to expand it.
src/plugins/help/helpplugin.cpp
+
16
−
0
View file @
e8161ebd
...
...
@@ -374,6 +374,17 @@ void HelpPlugin::createRightPaneSideBar()
m_helpViewerForSideBar
=
new
HelpViewer
(
m_helpEngine
,
0
);
rightPaneLayout
->
addWidget
(
m_helpViewerForSideBar
);
m_core
->
addContextObject
(
new
Core
::
BaseContext
(
m_helpViewerForSideBar
,
QList
<
int
>
()
<<
m_core
->
uniqueIDManager
()
->
uniqueIdentifier
(
Constants
::
C_HELP_SIDEBAR
),
this
));
QAction
*
copyActionSideBar
=
new
QAction
(
this
);
Core
::
Command
*
cmd
=
m_core
->
actionManager
()
->
registerAction
(
copyActionSideBar
,
Core
::
Constants
::
COPY
,
QList
<
int
>
()
<<
m_core
->
uniqueIDManager
()
->
uniqueIdentifier
(
Constants
::
C_HELP_SIDEBAR
));
connect
(
copyActionSideBar
,
SIGNAL
(
triggered
()),
this
,
SLOT
(
copyFromSideBar
()));
copyActionSideBar
->
setText
(
cmd
->
action
()
->
text
());
copyActionSideBar
->
setIcon
(
cmd
->
action
()
->
icon
());
m_rightPaneSideBar
=
new
QWidget
;
m_rightPaneSideBar
->
setLayout
(
rightPaneLayout
);
...
...
@@ -381,6 +392,11 @@ void HelpPlugin::createRightPaneSideBar()
addAutoReleasedObject
(
new
Core
::
BaseRightPaneWidget
(
m_rightPaneSideBar
));
}
void
HelpPlugin
::
copyFromSideBar
()
{
m_helpViewerForSideBar
->
copy
();
}
void
HelpPlugin
::
rightPaneBackward
()
{
m_helpViewerForSideBar
->
backward
();
...
...
This diff is collapsed.
Click to expand it.
src/plugins/help/helpplugin.h
+
5
−
4
View file @
e8161ebd
...
...
@@ -64,10 +64,10 @@ class SideBarItem;
namespace
Help
{
namespace
Constants
{
const
char
*
const
HELPVIEWER_KIND
=
"
Qt
Help
Viewer
"
;
const
char
*
const
C_
MODE_HELP
=
"Help
Mode
"
;
const
int
P_MODE_HELP
=
70
;
const
char
*
const
ID_MODE_HELP
=
"Help"
;
const
char
*
const
C_MODE_HELP
=
"Help
Mode
"
;
const
char
*
const
C_
HELP_SIDEBAR
=
"Help
Sidebar
"
;
const
int
P_MODE_HELP
=
70
;
const
char
*
const
ID_MODE_HELP
=
"Help"
;
}
class
HELP_EXPORT
HelpManager
:
public
QObject
...
...
@@ -124,6 +124,7 @@ private slots:
void
switchToHelpMode
(
const
QUrl
&
source
);
void
switchToHelpMode
(
const
QMap
<
QString
,
QUrl
>
&
urls
,
const
QString
&
keyword
);
void
slotHideRightPane
();
void
copyFromSideBar
();
void
openGettingStarted
();
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment