Changeset c54960cbe832f355a9a5b956a17b8199d2c3b1d0

Show
Ignore:
Timestamp:
01/06/07 23:44:42 (6 years ago)
Author:
Philipp Kern <phil@…>
Parents:
7bf4916ab93fbcb1e951abeeaf7bb1cf7bf96207
Children:
1bf177ad2724a9b25edab0e2a8716abd70bb6348
git-committer:
Philipp Kern <phil@0x539.de> / 2007-01-06T22:44:42Z+0000
Message:

[project @ Switch to tabs newly opened [fixes #27]]

Original author: Armin Burgmeier <armin@…>
Date: 2005-07-26 14:45:55+00:00

Location:
src
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • src/document.cpp

    reba1437 rc54960c  
    404404                } 
    405405        } 
     406 
     407        // Cursor moved because the introduction text has been deleted 
     408        m_signal_cursor_moved.emit(); 
     409        // Content changed because the introduction text has been deleted 
     410        m_signal_content_changed.emit(); 
    406411 
    407412        m_editing = false; 
  • src/window.cpp

    r7bf4916 rc54960c  
    402402        if(dlg.run() == Gtk::RESPONSE_OK) 
    403403        { 
     404                // " " means a newly created file 
     405                m_local_file_path = " "; 
     406                // Create new document 
    404407                m_buffer->create_document(dlg.get_text() ); 
    405408        } 
     
    733736        // Set the path from which this document was opened, if we opened that 
    734737        // file. 
    735         if(document.get_owner() == &m_buffer->get_self() ) 
    736                 doc->get_document().set_path(m_local_file_path); 
     738        if(document.get_owner() == &m_buffer->get_self() && 
     739           !m_local_file_path.empty() ) 
     740        { 
     741                // Select newly created page 
     742                m_folder.set_current_page(m_folder.get_n_pages() - 1); 
     743                doc->get_document().grab_focus(); 
     744 
     745                // " " is newly created, so we do not need a path 
     746                if(m_local_file_path != " ") 
     747                        doc->get_document().set_path(m_local_file_path); 
     748 
     749                // Crear local path 
     750                m_local_file_path.clear(); 
     751        } 
    737752 
    738753#if 0