コード例 #1
0
 private void OnSelectedInstructionChanged()
 {
     if (this.m_ListViewState.row >= 0)
     {
         if (this.m_Instruction == null)
         {
             this.m_Instruction = new GUIInstruction();
         }
         if (this.m_CachedinstructionInfo == null)
         {
             this.m_CachedinstructionInfo = new CachedInstructionInfo();
         }
         this.m_Instruction.rect           = GUIViewDebuggerHelper.GetRectFromInstruction(this.m_ListViewState.row);
         this.m_Instruction.usedGUIStyle   = GUIViewDebuggerHelper.GetStyleFromInstruction(this.m_ListViewState.row);
         this.m_Instruction.usedGUIContent = GUIViewDebuggerHelper.GetContentFromInstruction(this.m_ListViewState.row);
         this.m_Instruction.stackframes    = GUIViewDebuggerHelper.GetManagedStackTrace(this.m_ListViewState.row);
         this.m_CachedinstructionInfo.styleContainer.inspectedStyle  = this.m_Instruction.usedGUIStyle;
         this.m_CachedinstructionInfo.styleContainerSerializedObject = null;
         this.m_CachedinstructionInfo.styleSerializedProperty        = null;
         this.GetSelectedStyleProperty(out this.m_CachedinstructionInfo.styleContainerSerializedObject, out this.m_CachedinstructionInfo.styleSerializedProperty);
         this.HighlightInstruction(this.m_Inspected, this.m_Instruction.rect, this.m_Instruction.usedGUIStyle);
     }
     else
     {
         this.m_Instruction           = null;
         this.m_CachedinstructionInfo = null;
         if (this.m_InstructionOverlayWindow != null)
         {
             this.m_InstructionOverlayWindow.Close();
         }
     }
 }
コード例 #2
0
        internal override void OnSelectedInstructionChanged(int index)
        {
            listViewState.row = index;

            if (listViewState.row >= 0 && index < m_Instructions.Count)
            {
                if (m_CachedInstructionInfo == null)
                {
                    m_CachedInstructionInfo = new CachedInstructionInfo();
                }

                m_Instruction = m_Instructions[listViewState.row];

                //updated Cached data related to the Selected Instruction
                m_CachedInstructionInfo.styleContainer.inspectedStyle  = m_Instruction.usedGUIStyle;
                m_CachedInstructionInfo.styleContainerSerializedObject = null;
                m_CachedInstructionInfo.styleSerializedProperty        = null;
                GetSelectedStyleProperty(out m_CachedInstructionInfo.styleContainerSerializedObject, out m_CachedInstructionInfo.styleSerializedProperty);

                //Hightlight the item
                debuggerWindow.HighlightInstruction(debuggerWindow.inspected, m_Instruction.rect, m_Instruction.usedGUIStyle);
            }
            else
            {
                m_CachedInstructionInfo = null;

                debuggerWindow.ClearInstructionHighlighter();
            }
        }
コード例 #3
0
 public override void ClearRowSelection()
 {
     base.ClearRowSelection();
     m_CachedInstructionInfo = null;
 }
コード例 #4
0
 internal override void OnSelectedInstructionChanged(int index)
 {
     base.m_ListViewState.row = index;
     if (base.m_ListViewState.row >= 0)
     {
         if (this.m_Instruction == null)
         {
             this.m_Instruction = new GUIInstruction();
         }
         if (this.m_CachedinstructionInfo == null)
         {
             this.m_CachedinstructionInfo = new CachedInstructionInfo();
         }
         this.m_Instruction.rect = GUIViewDebuggerHelper.GetRectFromInstruction(base.m_ListViewState.row);
         this.m_Instruction.usedGUIStyle = GUIViewDebuggerHelper.GetStyleFromInstruction(base.m_ListViewState.row);
         this.m_Instruction.usedGUIContent = GUIViewDebuggerHelper.GetContentFromInstruction(base.m_ListViewState.row);
         this.m_Instruction.stackframes = GUIViewDebuggerHelper.GetManagedStackTrace(base.m_ListViewState.row);
         this.m_CachedinstructionInfo.styleContainer.inspectedStyle = this.m_Instruction.usedGUIStyle;
         this.m_CachedinstructionInfo.styleContainerSerializedObject = null;
         this.m_CachedinstructionInfo.styleSerializedProperty = null;
         this.GetSelectedStyleProperty(out this.m_CachedinstructionInfo.styleContainerSerializedObject, out this.m_CachedinstructionInfo.styleSerializedProperty);
         base.m_GuiViewDebuggerWindow.HighlightInstruction(base.m_GuiViewDebuggerWindow.m_Inspected, this.m_Instruction.rect, this.m_Instruction.usedGUIStyle);
     }
     else
     {
         this.m_Instruction = null;
         this.m_CachedinstructionInfo = null;
         if (base.m_GuiViewDebuggerWindow.InstructionOverlayWindow != null)
         {
             base.m_GuiViewDebuggerWindow.InstructionOverlayWindow.Close();
         }
     }
 }