]> git.siccegge.de Git - frida/frida.git/blobdiff - src/gui/widgets/BasicBlockWidget.hxx
Make function/jump targets clickable
[frida/frida.git] / src / gui / widgets / BasicBlockWidget.hxx
index 8aa182f671f94c130f923729ec4ef01a90053997..0087e05011d6d93bdbe7758779cb80a06342cc73 100644 (file)
@@ -13,7 +13,7 @@ class BasicBlockWidget : public QGraphicsItem
 public:
        BasicBlockWidget(const QString& name, BasicBlock * block);
 
-       void addItem(uint8_t* bytes, size_t num_bytes, const QString& line);
+       void addItem(uint8_t* bytes, size_t num_bytes, QString line, const QString& href);
 
        QRectF boundingRect() const  {
                qreal penWidth = 1;
@@ -32,9 +32,9 @@ public:
        }
 
        std::array<QPointF, 3> getExits() const {
-               return { {  mapToScene(QPointF(  width/3, height)),
-                                       mapToScene(QPointF(  width/2, height)),
-                                       mapToScene(QPointF(2*width/3, height)) } };
+               return { { mapToScene(QPointF(  width/3, height)),
+                          mapToScene(QPointF(  width/2, height)),
+                          mapToScene(QPointF(2*width/3, height)) } };
        }
 
        void paint(QPainter *painter, const QStyleOptionGraphicsItem *option,
@@ -58,6 +58,9 @@ public:
                return next;
        }
 
+       QString getName() const {
+               return name;
+       }
 private:
        uint32_t width, height;
        QGraphicsProxyWidget _proxy;