forked from qt-creator/qt-creator
Since we also license under GPL-3.0 WITH Qt-GPL-exception-1.0,
this applies only to a hypothetical newer version of GPL, that doesn't
exist yet. If such a version emerges, we can still decide to relicense...
While at it, replace (deprecated) GPL-3.0 with more explicit GPL-3.0-only
Change was done by running
find . -type f -exec perl -pi -e "s/LicenseRef-Qt-Commercial OR GPL-3.0\+ OR GPL-3.0 WITH Qt-GPL-exception-1.0/LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0/g" {} \;
Change-Id: I5097e6ce8d10233993ee30d7e25120e2659eb10b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
54 lines
1.4 KiB
C++
54 lines
1.4 KiB
C++
// Copyright (C) 2016 The Qt Company Ltd.
|
|
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
|
|
|
|
#pragma once
|
|
|
|
#include "breakhandler.h"
|
|
|
|
#include <QObject>
|
|
|
|
namespace Debugger::Internal {
|
|
|
|
class DebuggerEngine;
|
|
class DisassemblerAgentPrivate;
|
|
class DisassemblerLines;
|
|
class Location;
|
|
|
|
class DisassemblerAgent : public QObject
|
|
{
|
|
Q_OBJECT
|
|
Q_PROPERTY(QString mimeType READ mimeType WRITE setMimeType)
|
|
public:
|
|
// Called from Gui
|
|
explicit DisassemblerAgent(DebuggerEngine *engine);
|
|
~DisassemblerAgent() override;
|
|
|
|
void setLocation(const Location &location);
|
|
const Location &location() const;
|
|
void scheduleResetLocation();
|
|
void resetLocation();
|
|
void setContents(const DisassemblerLines &contents);
|
|
void updateLocationMarker();
|
|
void updateBreakpointMarker(const Breakpoint &bp);
|
|
void removeBreakpointMarker(const Breakpoint &bp);
|
|
|
|
// Mimetype: "text/a-asm" or some specialized architecture
|
|
QString mimeType() const;
|
|
Q_SLOT void setMimeType(const QString &mt);
|
|
|
|
quint64 address() const;
|
|
bool contentsCoversAddress(const QString &contents) const;
|
|
void cleanup();
|
|
|
|
// Force reload, e.g. after changing the output flavour.
|
|
void reload();
|
|
|
|
private:
|
|
void setContentsToDocument(const DisassemblerLines &contents);
|
|
int indexOf(const Location &loc) const;
|
|
|
|
DisassemblerAgentPrivate *d;
|
|
};
|
|
|
|
} // Debugger::Internal
|