Exemplo n.º 1
0
        private void DocumentServiceSaving(object sender, SledDocumentServiceEventArgs e)
        {
            m_sd = null;

            // Not connected (so can't edit & continue)
            if (!m_debugService.IsConnected)
            {
                return;
            }

            // File not in project
            if (e.Document.SledProjectFile == null)
            {
                return;
            }

            // File has no changes so nothing to update
            if (!e.Document.Dirty)
            {
                return;
            }

            // Store for edit & continue
            m_sd = e.Document;
        }
Exemplo n.º 2
0
 private void DocumentServiceSaved(object sender, SledDocumentServiceEventArgs e)
 {
     if (!Enable(e.Document))
     {
         Add(e.Document);
     }
 }
Exemplo n.º 3
0
        private void DocumentServiceOpened(object sender, SledDocumentServiceEventArgs e)
        {
            // We do a couple of things here:
            // 1) Draw current statement indicator if opened document matches breakpoint document
            // 2) Draw lock icon on documents opened while not stopped on a breakpoint

            var sd = e.Document;

            if (sd == null)
            {
                return;
            }

            // Don't care about non-project documents as they're not being debugged
            if (sd.SledProjectFile == null)
            {
                return;
            }

            // Don't care if disconnected
            if (m_debugService.IsDisconnected)
            {
                return;
            }

            if (m_debugService.IsDebugging)
            {
                // Not stopped on a breakpoint

                // Draw lock on document
                ((SledDocument)sd).IsReadOnly = true;
            }
            else
            {
                // Stopped on a breakpoint

                // Haven't hit a breakpoint yet so no where to jump to
                if (m_curBreakpoint == null)
                {
                    return;
                }

                // Check if the opened document is the breakpoint document
                // and if it is draw the current statement indicator and jump
                // to the breakpoint line
                if (string.Compare(sd.SledProjectFile.Path, m_curBreakpoint.File, true) == 0)
                {
                    // Jump to line & draw current statement indicator
                    m_gotoService.Get.GotoLine(e.Document, m_curBreakpoint.Line, true);
                }
            }
        }
Exemplo n.º 4
0
        private void DocumentServiceSaved(object sender, SledDocumentServiceEventArgs e)
        {
            // No document to deal with
            if (m_sd == null)
            {
                return;
            }

            // Out of whack somehow?
            if (m_sd != e.Document)
            {
                return;
            }

            HandleEditAndContinue(m_sd);

            // Reset
            m_sd = null;
        }
Exemplo n.º 5
0
        private void DocumentServiceSaved(object sender, SledDocumentServiceEventArgs e)
        {
            // No document to deal with
            if (m_sd == null)
            {
                return;
            }

            // Out of whack somehow?
            if (m_sd != e.Document)
            {
                return;
            }

            // JC2MP doesn't support this, so why show the window? :^)
            // HandleEditAndContinue(m_sd);

            // Reset
            m_sd = null;
        }
Exemplo n.º 6
0
 private void DocumentServiceClosing(object sender, SledDocumentServiceEventArgs e)
 {
     // Remove any current statement indicators
     RemoveCurrentStatementIndicators(e.Document);
 }
Exemplo n.º 7
0
 private void DocumentService_Closed(object sender, SledDocumentServiceEventArgs e)
 {
     SledOutDevice.OutLine(SledMessageType.Info, "ISledDocumentService.Closed");
 }
Exemplo n.º 8
0
 private void DocumentService_Saving(object sender, SledDocumentServiceEventArgs e)
 {
     SledOutDevice.OutLine(SledMessageType.Info, "ISledDocumentService.Saving");
 }
Exemplo n.º 9
0
 private void DocumentServiceClosing(object sender, SledDocumentServiceEventArgs e)
 {
     e.Document.DirtyChanged -= SledDocumentDirtyChanged;
 }
Exemplo n.º 10
0
 private void DocumentServiceOpened(object sender, SledDocumentServiceEventArgs e)
 {
     e.Document.DirtyChanged += SledDocumentDirtyChanged;
 }
Exemplo n.º 11
0
 private void DocumentServiceSaved(object sender, SledDocumentServiceEventArgs e)
 {
     AddToBatchQueue(new[] { e.Document.SledProjectFile });
 }
Exemplo n.º 12
0
 private void DocumentServiceClosing(object sender, SledDocumentServiceEventArgs e)
 {
     Remove(e.Document);
 }
Exemplo n.º 13
0
 private void DocumentServiceSaving(object sender, SledDocumentServiceEventArgs e)
 {
     Disable(e.Document);
 }
Exemplo n.º 14
0
 private void DocumentServiceOpened(object sender, SledDocumentServiceEventArgs e)
 {
     Add(e.Document);
 }
 private void DocumentServiceOpened(object sender, SledDocumentServiceEventArgs e)
 {
     RegisterDocument(e.Document);
 }
 private void DocumentServiceClosing(object sender, SledDocumentServiceEventArgs e)
 {
     UnregisterDocument(e.Document);
 }