Ejemplo n.º 1
0
        public void Inspect(PackedManagedObject managedObject)
        {
            m_ManagedObject = new RichManagedObject(snapshot, managedObject.managedObjectsArrayIndex);
            m_ManagedType   = m_ManagedObject.type;
            m_PropertyGrid.Inspect(snapshot, m_ManagedObject.packed);

            m_DataVisualizer = null;
            if (AbstractDataVisualizer.HasVisualizer(m_ManagedObject.type.name))
            {
                m_DataVisualizer = AbstractDataVisualizer.CreateVisualizer(m_ManagedObject.type.name);
                m_DataVisualizer.Initialize(snapshot, new MemoryReader(snapshot), m_ManagedObject.address, m_ManagedObject.type.packed);
            }

            m_HexView.Inspect(snapshot, managedObject.address, (ulong)managedObject.size);
        }
Ejemplo n.º 2
0
        void TryCreateDataVisualizer(AbstractMemoryReader reader, PackedManagedType type, ulong address, bool resolveAddress)
        {
            m_DataVisualizer          = null;
            m_DataVisualizerScrollPos = new Vector2();

            //if (AbstractDataVisualizer.HasVisualizer(type.name))
            {
                if (type.isPointer && resolveAddress)
                {
                    address = reader.ReadPointer(address);
                }

                m_DataVisualizer = AbstractDataVisualizer.CreateVisualizer(type.name);
                m_DataVisualizer.Initialize(m_Snapshot, reader, address, type);
            }
        }
Ejemplo n.º 3
0
        public static EditorWindow CreateWindow(PackedMemorySnapshot snapshot, AbstractMemoryReader memoryReader, System.UInt64 address, PackedManagedType type)
        {
            var visualizer = AbstractDataVisualizer.CreateVisualizer(type.name);

            if (visualizer == null)
            {
                Debug.LogWarningFormat("Could not create DataVisualizer for type '{0}'", type.name);
                return(null);
            }
            visualizer.Initialize(snapshot, memoryReader, address, type);

            var window = DataVisualizerWindow.CreateInstance <DataVisualizerWindow>();

            window.SetVisualizer(visualizer);
            window.ShowUtility();
            return(window);
        }