Skip to content

Commit 15a836a

Browse files
committed
Improve container-aware display names in projects.
1 parent eab54b0 commit 15a836a

2 files changed

Lines changed: 10 additions & 4 deletions

File tree

ui/uicontext.h

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -561,10 +561,10 @@ class BINARYNINJAUIAPI UIContext
561561
virtual ProjectRef getProject();
562562
virtual ProjectStatusWidget* getProjectStatusWidget();
563563

564-
virtual bool openFilename(const QString& path, bool openOptions = false);
564+
virtual bool openFilename(const QString& path, bool openOptions = false, bool forceContainerBrowser = false);
565565
virtual ProjectRef openProject(const QString& path);
566566
virtual ViewFrame* openFileContext(FileContext* file, const QString& forcedView = "", bool addTab = true);
567-
virtual bool openProjectFile(ProjectFileRef file, ExternalLocationRef loc = nullptr, bool openWithOptions = false);
567+
virtual bool openProjectFile(ProjectFileRef file, ExternalLocationRef loc = nullptr, bool openWithOptions = false, bool forceContainerBrowser = false);
568568
virtual bool openUrl(const QUrl& url, bool openWithOptions = false);
569569
virtual void recreateViewFrames(FileContext* file) = 0;
570570
virtual void refreshCurrentViewContents();
@@ -629,6 +629,12 @@ class BINARYNINJAUIAPI UIContext
629629
\return Name to display for this path
630630
*/
631631
QString GetNameForPath(const QString& path);
632+
/*!
633+
Get the displayed name for a file, resolving container entries within projects
634+
\param metadata FileMetadata whose displayed name you want
635+
\return Name to display for this file
636+
*/
637+
QString GetNameForPath(FileMetadataRef metadata);
632638

633639
virtual QWidget* fileContentsLockStatusWidget() = 0;
634640

ui/uitypes.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,14 @@
66
// there are changes to the API that affect linking, including new functions,
77
// new types, modifications to existing functions or types, or new versions
88
// of the Qt libraries.
9-
#define BN_CURRENT_UI_ABI_VERSION 12
9+
#define BN_CURRENT_UI_ABI_VERSION 13
1010

1111
// Minimum ABI version that is supported for loading of plugins. Plugins that
1212
// are linked to an ABI version less than this will not be able to load and
1313
// will require rebuilding. The minimum version is increased when there are
1414
// incompatible changes that break binary compatibility, such as changes to
1515
// existing types or functions, or a new version of Qt.
16-
#define BN_MINIMUM_UI_ABI_VERSION 12
16+
#define BN_MINIMUM_UI_ABI_VERSION 13
1717

1818
#ifdef __GNUC__
1919
#ifdef BINARYNINJAUI_LIBRARY

0 commit comments

Comments
 (0)