2015-11-23 16:41:54 +01:00
|
|
|
/****************************************************************************
|
|
|
|
|
**
|
2016-01-15 14:57:40 +01:00
|
|
|
** Copyright (C) 2016 The Qt Company Ltd.
|
|
|
|
|
** Contact: https://www.qt.io/licensing/
|
2015-11-23 16:41:54 +01:00
|
|
|
**
|
|
|
|
|
** This file is part of Qt Creator.
|
|
|
|
|
**
|
|
|
|
|
** Commercial License Usage
|
|
|
|
|
** Licensees holding valid commercial Qt licenses may use this file in
|
|
|
|
|
** accordance with the commercial license agreement provided with the
|
|
|
|
|
** Software or, alternatively, in accordance with the terms contained in
|
2016-01-15 14:57:40 +01:00
|
|
|
** a written agreement between you and The Qt Company. For licensing terms
|
|
|
|
|
** and conditions see https://www.qt.io/terms-conditions. For further
|
|
|
|
|
** information use the contact form at https://www.qt.io/contact-us.
|
2015-11-23 16:41:54 +01:00
|
|
|
**
|
2016-01-15 14:57:40 +01:00
|
|
|
** GNU General Public License Usage
|
|
|
|
|
** Alternatively, this file may be used under the terms of the GNU
|
|
|
|
|
** General Public License version 3 as published by the Free Software
|
|
|
|
|
** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
|
|
|
|
|
** included in the packaging of this file. Please review the following
|
|
|
|
|
** information to ensure the GNU General Public License requirements will
|
|
|
|
|
** be met: https://www.gnu.org/licenses/gpl-3.0.html.
|
2015-11-23 16:41:54 +01:00
|
|
|
**
|
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
2016-03-18 07:55:01 +01:00
|
|
|
#pragma once
|
2015-11-23 16:41:54 +01:00
|
|
|
|
2016-06-27 14:38:36 +02:00
|
|
|
#include "debugger_global.h"
|
|
|
|
|
|
2015-11-23 16:41:54 +01:00
|
|
|
#include <utils/icon.h>
|
|
|
|
|
|
|
|
|
|
namespace Debugger {
|
|
|
|
|
namespace Icons {
|
|
|
|
|
|
2016-06-27 14:38:36 +02:00
|
|
|
// Used in QmlProfiler.
|
|
|
|
|
DEBUGGER_EXPORT extern const Utils::Icon RECORD_ON;
|
|
|
|
|
DEBUGGER_EXPORT extern const Utils::Icon RECORD_OFF;
|
|
|
|
|
|
2018-04-26 16:02:59 +02:00
|
|
|
DEBUGGER_EXPORT extern const Utils::Icon TRACEPOINT;
|
|
|
|
|
DEBUGGER_EXPORT extern const Utils::Icon TRACEPOINT_TOOLBAR;
|
|
|
|
|
|
2016-06-27 14:38:36 +02:00
|
|
|
extern const Utils::Icon BREAKPOINT;
|
|
|
|
|
extern const Utils::Icon BREAKPOINT_DISABLED;
|
|
|
|
|
extern const Utils::Icon BREAKPOINT_PENDING;
|
|
|
|
|
extern const Utils::Icon BREAKPOINTS;
|
|
|
|
|
extern const Utils::Icon WATCHPOINT;
|
|
|
|
|
extern const Utils::Icon CONTINUE;
|
|
|
|
|
extern const Utils::Icon CONTINUE_FLAT;
|
|
|
|
|
extern const Utils::Icon DEBUG_CONTINUE_SMALL;
|
|
|
|
|
extern const Utils::Icon DEBUG_CONTINUE_SMALL_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon INTERRUPT;
|
|
|
|
|
extern const Utils::Icon INTERRUPT_FLAT;
|
2018-10-04 14:44:39 +02:00
|
|
|
extern const Utils::Icon STOP_FLAT;
|
2016-06-27 14:38:36 +02:00
|
|
|
extern const Utils::Icon DEBUG_INTERRUPT_SMALL;
|
|
|
|
|
extern const Utils::Icon DEBUG_INTERRUPT_SMALL_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon DEBUG_EXIT_SMALL;
|
|
|
|
|
extern const Utils::Icon DEBUG_EXIT_SMALL_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon LOCATION;
|
Debugger: Make most views per-engine instead of singletons
This is a step towards properly supporting multiple debugger
sessions side-by-side.
The combined C++-and-QML engine has been removed, instead a
combined setup creates now two individual engines, under a single
DebuggerRunTool but mostly independent with no combined state
machine. This requires a few more clicks in some cases, but
makes it easier to direct e.g. interrupt requests to the
interesting engine.
Care has been taken to not change the UX of the single debugger
session use case if possible. The fat debug button operates
as-before in that case, i.e. switches to Interrupt if the
single active runconfiguration runs in the debugger etc.
Most views are made per-engine, running an engine creates
a new Perspective, which is destroyed when the run control dies.
The snapshot view remains global and becomes primary source
of information on a "current engine" that receives all menu
and otherwise global input.
There is a new global "Breakpoint Preset" view containing
all "static" breakpoint data. When an engine starts up it
"claims" breakpoint it believes it can handle, but operates
on a copy of the static data. The markers of the static
version are suppressed as long as an engine controls a
breakpoint (that inclusive all resolved locations), but are
re-instatet once the engine quits.
The old Breakpoint class that already contained this split
per-instance was split into a new Breakpoint and a
GlobalBreakpoint class, with a per-engine model for Breakpoints,
and a singleton model containing GlobalBreakpoints.
There is a new CppDebuggerEngine intermediate level serving as
base for C++ (or, rather, "compiled") binary debugging, i.e.
{Gdb,Lldb,Cdb}Engine, taking over bits of the current DebuggerEngine
base that are not applicable to non-binary debuggers.
Change-Id: I9994f4c188379b4aee0c4f379edd4759fbb0bd43
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2018-07-31 12:30:48 +02:00
|
|
|
extern const Utils::Icon REVERSE_LOCATION;
|
2016-06-27 14:38:36 +02:00
|
|
|
extern const Utils::Icon REVERSE_MODE;
|
Debugger: Make most views per-engine instead of singletons
This is a step towards properly supporting multiple debugger
sessions side-by-side.
The combined C++-and-QML engine has been removed, instead a
combined setup creates now two individual engines, under a single
DebuggerRunTool but mostly independent with no combined state
machine. This requires a few more clicks in some cases, but
makes it easier to direct e.g. interrupt requests to the
interesting engine.
Care has been taken to not change the UX of the single debugger
session use case if possible. The fat debug button operates
as-before in that case, i.e. switches to Interrupt if the
single active runconfiguration runs in the debugger etc.
Most views are made per-engine, running an engine creates
a new Perspective, which is destroyed when the run control dies.
The snapshot view remains global and becomes primary source
of information on a "current engine" that receives all menu
and otherwise global input.
There is a new global "Breakpoint Preset" view containing
all "static" breakpoint data. When an engine starts up it
"claims" breakpoint it believes it can handle, but operates
on a copy of the static data. The markers of the static
version are suppressed as long as an engine controls a
breakpoint (that inclusive all resolved locations), but are
re-instatet once the engine quits.
The old Breakpoint class that already contained this split
per-instance was split into a new Breakpoint and a
GlobalBreakpoint class, with a per-engine model for Breakpoints,
and a singleton model containing GlobalBreakpoints.
There is a new CppDebuggerEngine intermediate level serving as
base for C++ (or, rather, "compiled") binary debugging, i.e.
{Gdb,Lldb,Cdb}Engine, taking over bits of the current DebuggerEngine
base that are not applicable to non-binary debuggers.
Change-Id: I9994f4c188379b4aee0c4f379edd4759fbb0bd43
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2018-07-31 12:30:48 +02:00
|
|
|
extern const Utils::Icon DIRECTION_FORWARD;
|
|
|
|
|
extern const Utils::Icon DIRECTION_BACKWARD;
|
2016-06-27 14:38:36 +02:00
|
|
|
extern const Utils::Icon APP_ON_TOP;
|
|
|
|
|
extern const Utils::Icon APP_ON_TOP_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon SELECT;
|
|
|
|
|
extern const Utils::Icon SELECT_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon EMPTY;
|
2015-11-23 16:41:54 +01:00
|
|
|
|
2016-06-27 14:38:36 +02:00
|
|
|
extern const Utils::Icon STEP_OVER;
|
|
|
|
|
extern const Utils::Icon STEP_OVER_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon STEP_INTO;
|
|
|
|
|
extern const Utils::Icon STEP_INTO_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon STEP_OUT;
|
|
|
|
|
extern const Utils::Icon STEP_OUT_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon RESTART;
|
|
|
|
|
extern const Utils::Icon RESTART_TOOLBAR;
|
|
|
|
|
extern const Utils::Icon SINGLE_INSTRUCTION_MODE;
|
2015-11-23 16:41:54 +01:00
|
|
|
|
2016-06-27 14:38:36 +02:00
|
|
|
extern const Utils::Icon MODE_DEBUGGER_CLASSIC;
|
|
|
|
|
extern const Utils::Icon MODE_DEBUGGER_FLAT;
|
|
|
|
|
extern const Utils::Icon MODE_DEBUGGER_FLAT_ACTIVE;
|
2015-11-11 19:26:58 +01:00
|
|
|
|
Add macOS touch bar support
Introduce a generic Utils::TouchBar that implements a touch bar for
macOS based on QAction. Touch bars can be nested, and one is set to be
the application's top level touch bar.
Also add an ActionContainer for the touch bar. That allows us to manage
the layout of the touch bar the same way we do with menus.
Since the touch bar is an input device with very limited space, a
command in the touch bar needs to be specifically styled for the touch
bar by setting either touchBarText or touchBarIcon (or both).
Touch bars can be nested by nesting the ActionContainers. A nested touch
bar ActionContainer needs to specify an icon and/or text to show in the
touch bar button that opens that sub-bar.
Commands are only shown in the touch bar if they are valid within the
current context.
Implementation-wise we cannot use the standard NSPopoverTouchBarItem for
nesting touch bar levels. We cannot hide items in the touch bar, because
hidden items still take up space in the touch bar. So we need to rebuild
the touch bar regularly. Since the items we show are very dynamic, every
time the items in the toplevel bar change because of a context change,
any opened sub-level touch bar closes. That is why we maintain a stack of
touch bar levels ourselves, replacing the main touch bar with the current
level, and managing opening and closing the levels manually.
This patch adds buttons for Help, Bookmarks, Header/Source, Follow
(Symbol), Decl/Def, and a sub-bar for the debugger actions.
Fixes: QTCREATORBUG-21263
Change-Id: Ib63e610f21a993f1d324fe23c83a7f2224f434ac
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
2018-10-05 13:52:57 +02:00
|
|
|
extern const Utils::Icon MACOS_TOUCHBAR_DEBUG;
|
|
|
|
|
extern const Utils::Icon MACOS_TOUCHBAR_DEBUG_EXIT;
|
|
|
|
|
extern const Utils::Icon MACOS_TOUCHBAR_DEBUG_INTERRUPT;
|
|
|
|
|
extern const Utils::Icon MACOS_TOUCHBAR_DEBUG_CONTINUE;
|
|
|
|
|
extern const Utils::Icon MACOS_TOUCHBAR_DEBUG_STEP_OVER;
|
|
|
|
|
extern const Utils::Icon MACOS_TOUCHBAR_DEBUG_STEP_INTO;
|
|
|
|
|
extern const Utils::Icon MACOS_TOUCHBAR_DEBUG_STEP_OUT;
|
|
|
|
|
|
2015-11-23 16:41:54 +01:00
|
|
|
} // namespace Icons
|
|
|
|
|
} // namespace Debugger
|