packages: kde4-kdelibs/kde4-kdelibs-branch.diff, kde4-kdelibs/kde4-kdelibs....
arekm
arekm at pld-linux.org
Wed Dec 2 19:12:47 CET 2009
Author: arekm Date: Wed Dec 2 18:12:47 2009 GMT
Module: packages Tag: HEAD
---- Log message:
- rel 3; branch diff is back
---- Files affected:
packages/kde4-kdelibs:
kde4-kdelibs-branch.diff (1.16 -> 1.17) , kde4-kdelibs.spec (1.174 -> 1.175)
---- Diffs:
================================================================
Index: packages/kde4-kdelibs/kde4-kdelibs-branch.diff
diff -u packages/kde4-kdelibs/kde4-kdelibs-branch.diff:1.16 packages/kde4-kdelibs/kde4-kdelibs-branch.diff:1.17
--- packages/kde4-kdelibs/kde4-kdelibs-branch.diff:1.16 Wed Nov 25 10:41:46 2009
+++ packages/kde4-kdelibs/kde4-kdelibs-branch.diff Wed Dec 2 19:12:41 2009
@@ -1,2041 +1,327 @@
-Index: cmake/modules/FindPhonon.cmake
+Index: kio/kio/slave.cpp
===================================================================
---- cmake/modules/FindPhonon.cmake (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ cmake/modules/FindPhonon.cmake (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -35,7 +35,7 @@
- # then at the default system locations (CMAKE_SYSTEM_PREFIX_PATH, i.e. /usr etc.)
- find_library(PHONON_LIBRARY NAMES phonon)
-
-- find_path(PHONON_INCLUDE_DIR NAMES phonon/phonon_export.h PATHS ${KDE4_INCLUDE_INSTALL_DIR} ${QT_INCLUDE_DIR} ${INCLUDE_INSTALL_DIR} NO_SYSTEM_ENVIRONMENT_PATH NO_CMAKE_SYSTEM_PATH)
-+ find_path(PHONON_INCLUDE_DIR NAMES phonon/phonon_export.h PATHS ${KDE4_INCLUDE_INSTALL_DIR} ${QT_INCLUDE_DIR} ${QT_LIBRARY_DIR} ${INCLUDE_INSTALL_DIR} NO_SYSTEM_ENVIRONMENT_PATH NO_CMAKE_SYSTEM_PATH)
- find_path(PHONON_INCLUDE_DIR NAMES phonon/phonon_export.h)
+--- kio/kio/slave.cpp (.../tags/KDE/4.3.4/kdelibs) (wersja 1057516)
++++ kio/kio/slave.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1057516)
+@@ -125,9 +125,10 @@
+ void Slave::timeout()
+ {
+ Q_D(Slave);
++ if (d->dead)
++ return;
+ if (d->connection->isConnected())
+ return;
+-
+ kDebug(7002) << "slave failed to connect to application pid=" << d->m_pid << " protocol=" << d->m_protocol;
+ if (d->m_pid && (::kill(d->m_pid, 0) == 0))
+ {
+Index: kio/kio/jobuidelegate.cpp
+===================================================================
+--- kio/kio/jobuidelegate.cpp (.../tags/KDE/4.3.4/kdelibs) (wersja 1057516)
++++ kio/kio/jobuidelegate.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1057516)
+@@ -79,17 +79,19 @@
+ sizeSrc, sizeDest,
+ ctimeSrc, ctimeDest, mtimeSrc,
+ mtimeDest);
++ connect(job, SIGNAL(finished(KJob*)), &dlg, SLOT(reject())); // #192976
+ KIO::RenameDialog_Result res = static_cast<RenameDialog_Result>(dlg.exec());
+ newDest = dlg.newDestUrl().path();
+ return res;
+ }
+
+-KIO::SkipDialog_Result KIO::JobUiDelegate::askSkip(KJob *,
++KIO::SkipDialog_Result KIO::JobUiDelegate::askSkip(KJob *job,
+ bool multi,
+ const QString & error_text)
+ {
+ // We now do it in process. So this method is a useless wrapper around KIO::open_RenameDialog.
+ KIO::SkipDialog dlg( window(), multi, error_text );
++ connect(job, SIGNAL(finished(KJob*)), &dlg, SLOT(reject())); // #192976
+ return static_cast<KIO::SkipDialog_Result>(dlg.exec());
+ }
+
+Index: kio/kio/kzip.h
+===================================================================
+--- kio/kio/kzip.h (.../tags/KDE/4.3.4/kdelibs) (wersja 1057516)
++++ kio/kio/kzip.h (.../branches/KDE/4.3/kdelibs) (wersja 1057516)
+@@ -149,9 +149,7 @@
+ /// Closes the archive
+ virtual bool closeArchive();
- if(PHONON_INCLUDE_DIR AND PHONON_LIBRARY)
-Index: kate/render/katerenderer.h
-===================================================================
---- kate/render/katerenderer.h (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/render/katerenderer.h (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -236,6 +236,8 @@
- int cursorToX(const KateTextLayout& range, int col) const;
- /// \overload
- int cursorToX(const KateTextLayout& range, const KTextEditor::Cursor& pos) const;
-+ /// \overload
-+ int cursorToX(const KateTextLayout& range, const KTextEditor::Cursor& pos, bool returnPastLine) const;
-
- /**
- * Returns the real cursor which is occupied by the specified x value, or that closest to it.
-Index: kate/render/katerenderer.cpp
-===================================================================
---- kate/render/katerenderer.cpp (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/render/katerenderer.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -660,7 +660,7 @@
- const KateTextLayout& lastLine = range->viewLine(range->viewLineCount() - 1);
- int x = range->widthOfLastLine() + spaceWidth() * (cursor->column() - range->length());
- if ( (x >= xStart) && (x <= xEnd))
-- paint.fillRect(x, (int)lastLine.lineLayout().y(), caretWidth, fm.height(), c);
-+ paint.fillRect(x-xStart, (int)lastLine.lineLayout().y(), caretWidth, fm.height(), c);
- }
- }
- }
-@@ -903,6 +903,17 @@
- return (int)range.lineLayout().cursorToX(pos.column());
- }
-
-+int KateRenderer::cursorToX(const KateTextLayout& range, const KTextEditor::Cursor & pos, bool returnPastLine) const
-+{
-+ int x = cursorToX(range, pos);
-+ int over = pos.column() * spaceWidth() - range.width();
-+
-+ if (returnPastLine && over > 0)
-+ x += over;
-+
-+ return x;
-+}
-+
- KTextEditor::Cursor KateRenderer::xToCursor(const KateTextLayout & range, int x, bool returnPastLine ) const
- {
- Q_ASSERT(range.isValid());
-Index: kate/syntax/data/lilypond.xml
-===================================================================
---- kate/syntax/data/lilypond.xml (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/syntax/data/lilypond.xml (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -8,7 +8,7 @@
- <!ENTITY scripts "\d+|accent|marcato|staccat(issim)?o|espressivo|tenuto|portato|(up|down)(bow|mordent|prall)|flageolet|thumb|[lr](heel|toe)|open|stopped|turn|reverseturn|trill|mordent|prall(prall|mordent|down|up)?|lineprall|signumcongruentiae|(short|long|verylong)?fermata|segno|(var)?coda">
- <!ENTITY keywords "accepts|alias|consists|defaultchild|denies|description|grobdescriptions|include|invalid|name|objectid|once|remove|sequential|simultaneous|type|version|score|book|bookpart">
- <!ENTITY deprecatedkeywords "consistsend">
-- <!ENTITY commands "acciaccatura|addQuote|afterGrace|aikenHeads|allowPageTurn|alternative|apply(Context|Music|Output)|appoggiatura|arpeggio(Arrow(Down|Up)|Bracket|Normal|Parenthesis)?|(a|de)scendens|auctum|augmentum|autoBeamO(ff|n)|autochange|balloon(Grob)?Text|bar|barNumberCheck|bendAfter|breathe|break|cadenzaO(ff|n)|cavum|clef(\s+(treble|violin|G|alto|C|tenor|(sub)?bass|F|french|(mezzo)?soprano|(var)?baritone|percussion|tab))?|(end)?(de)?cr|cresc(TextCresc|Hairpin)|(cue|transposedCue)During|default|deminutum|dim(Text(Decresc|Decr|Dim)|Hairpin)|display(Lily)?Music|divisio(Maior|Maxima|Minima)|(dynamic|dots|phrasingSlur|slur|stem|tie|tuplet)(Down|Neutral|Up)|(balloon|text)LengthO(ff|n)|featherDurations|figure(mode|s)|finalis|flexa|(french|german|italian|semiGerman)Chords|glissando|grace|harmonic|(unH|h)ideNotes|(hide|show)StaffSwitch|inclinatum|(keep|remove)WithTag|key(\s+&pitch;)?|killCues|label|laissezVibrer|linea|mark|maxima|melisma(End)?|mergeDifferently(Head|Dott)edO(
ff|n)|newSpacingSection|no(Beam|Break|PageBreak|PageTurn)|normalsize|numericTimeSignature|octaveCheck|oneVoice|oriscus|ottava|page(-ref|Break|Turn)|parallelMusic|parenthesize|partcombine|partial(\s*&duration;)?|pes|pitchedTrill|pointAndClickO(ff|n)|quilisma|quoteDuring|relative(\s+&pitch;)?|RemoveEmptyStaffContext|repeat(\s+(unfold|volta|tremolo|percent)(\s+\d+)?)?|repeatTie|resetRelativeOctave|rest|sacredHarpHeads|scaleDurations|scoreTweak|easyHeadsO(ff|n)|shift(Durations|Off|On{1,3})|(slur|tie)(Both|Dashed|Dotted|Solid)|small|spacingTweaks|(start|stop)(Group|(Text|Trill)Span|Staff)|stemBoth|stropha|super|(sustain|sostenuto)O(ff|n)|table-of-contents|tag|times?(\s*\d+/\d+)?|tiny|tocItem|transpose(\s+&pitch;\s*&pitch;)?|transposition(\s+&pitch;)|tweak|unfoldRepeats|virg(ul)?a|voice(One|Two|Three|Four)|withMusicProperty|cm|mm|in|pt|major|minor|ionian|locrian|aeolian|mixolydian|lydian|phrygian|dorian">
-+ <!ENTITY commands "acciaccatura|addQuote|afterGrace|aikenHeads|allowPageTurn|alternative|apply(Context|Music|Output)|appoggiatura|arpeggio(Arrow(Down|Up)|Bracket|Normal|Parenthesis)?|(a|de)scendens|auctum|augmentum|autoBeamO(ff|n)|autochange|balloon(Grob)?Text|bar|barNumberCheck|bendAfter|breathe|break|cadenzaO(ff|n)|cavum|clef(\s+(treble|violin|G|alto|C|tenor|(sub)?bass|F|french|(mezzo)?soprano|(var)?baritone|percussion|tab))?|(end)?(de)?cr|cresc(TextCresc|Hairpin)|(cue|transposedCue)During|default|deminutum|dim(Text(Decresc|Decr|Dim)|Hairpin)|display(Lily)?Music|divisio(Maior|Maxima|Minima)|(dynamic|dots|phrasingSlur|slur|stem|tie|tuplet)(Down|Neutral|Up)|(balloon|text)LengthO(ff|n)|featherDurations|figure(mode|s)|finalis|flexa|(french|german|italian|semiGerman)Chords|glissando|grace|harmonic|(unH|h)ideNotes|(hide|show)StaffSwitch|inclinatum|(keep|remove)WithTag|key(\s+&pitch;)?|killCues|label|laissezVibrer|linea|makeClusters|mark|maxima|melisma(End)?|mergeDifferently(H
ead|Dott)edO(ff|n)|newSpacingSection|no(Beam|Break|PageBreak|PageTurn)|normalsize|numericTimeSignature|octaveCheck|oneVoice|oriscus|ottava|page(-ref|Break|Turn)|parallelMusic|parenthesize|partcombine|partial(\s*&duration;)?|pes|pitchedTrill|pointAndClickO(ff|n)|quilisma|quoteDuring|relative(\s+&pitch;)?|RemoveEmptyStaffContext|repeat(\s+(unfold|volta|tremolo|percent)(\s+\d+)?)?|repeatTie|resetRelativeOctave|rest|sacredHarpHeads|scaleDurations|scoreTweak|easyHeadsO(ff|n)|shift(Durations|Off|On{1,3})|(slur|tie)(Both|Dashed|Dotted|Solid)|small|spacingTweaks|(start|stop)(Group|(Text|Trill)Span|Staff)|stemBoth|stropha|super|(sustain|sostenuto)O(ff|n)|table-of-contents|tag|times?(\s*\d+/\d+)?|tiny|tocItem|transpose(\s+&pitch;\s*&pitch;)?|transposition(\s+&pitch;)|tweak|unfoldRepeats|virg(ul)?a|voice(One|Two|Three|Four)|withMusicProperty|cm|mm|in|pt|major|minor|ionian|locrian|aeolian|mixolydian|lydian|phrygian|dorian">
- <!ENTITY deprecatedcommands "arpeggio(Up|Down|Neutral)|newpage|script(Up|Down|Both)|(empty|fat)Text|setEasyHeads|(default|voice|modernVoice|piano|forget)Accidentals|(modern(Voice)?|piano)Cautionaries|noResetKey|compressMusic|octave|(sustain|sostenuto)(Down|Up)|set(Hairpin|Text)(Cresc|Decresc|Dim)|setTextDecr">
- <!ENTITY markupnotextargs "arrow-head|beam|char|(semi|sesqui|double)?(flat|sharp)|draw-(circle|line)|epsfile|filled-box|fret-diagram(-terse|-verbose)?|fromproperty|harp-pedal|(justify|wordwrap)-(field|string)|lookup|markalphabet|markletter|musicglyph|natural|note-by-number|note|null|simple|(back)?slashed-digit|stencil|strut|tied-lyric|triangle|verbatim-file">
- <!ENTITY markupwithtextargs "markup|bold|(rounded-)?box|bracket|caps|(center|general|left|right)-align|circle|((center|dir|left|right)-)?column|combine|concat|dynamic|fill-line|finger|fontCaps|(abs-)?fontsize|fraction|halign|hbracket|hcenter-in|hcenter|hspace|huge|italic|justify|larger?|line|lower|magnify|medium|normal-size-(sub|super)|normal-text|normalsize|number|on-the-fly|override|pad-(around|markup|to-box|x)|page-ref|postscript|put-adjacent|raise|roman|rotate|sans|small(er)?|smallCaps|sub|super|teeny|text|tiny|translate(-scaled)?|transparent|typewriter|underline|upright|vcenter|whiteout|with-(color|dimensions|url)|wordwrap|(markup|column-|justified-|override-|wordwrap-)lines|wordwrap-(string-)?internal">
-@@ -26,13 +26,21 @@
- ]>
- <language name="LilyPond" section="Other"
- style="lilypond" indenter="lilypond"
-- version="3.04" kateversion="3.0"
-+ version="3.05" kateversion="3.0"
- extensions="*.ly;*.LY;*.ily;*.ILY;*.lyi;*.LYI"
- mimetype="text/x-lilypond"
- author="Wilbert Berendsen (info at wilbertberendsen.nl)" license="LGPL">
-
- <!--
-
-+ November, 2009
-+ Minor updates by Wilbert Berendsen
-+
-+ Changes:
-+
-+ - add makeClusters
-+ - fix chords in drummode
-+
- October, 2008
- Minor updates by Wilbert Berendsen
-
-@@ -882,9 +890,15 @@
- <context name="drumrules" attribute="Normal Text" lineEndContext="#stay">
- <DetectChar char="{" attribute="Keyword" context="drumrules" beginRegion="sequential"/>
- <DetectChar char="}" attribute="Keyword" context="#pop" endRegion="sequential"/>
-+ <RegExpr String="<(?!<)" attribute="Chord" context="drumchord"/>
- <keyword attribute="Other Text" String="drumpitchnames" context="duration"/>
- <IncludeRules context="music"/>
- </context>
-+
-+ <context name="drumchord" attribute="Normal Text" lineEndContext="#stay">
-+ <keyword attribute="Other Text" String="drumpitchnames"/>
-+ <IncludeRules context="chord"/>
-+ </context>
-
- <!-- Chordmode -->
- <context name="chordmode" attribute="Other Mode" lineEndContext="#stay"
-Index: kate/utils/kateautoindent.cpp
-===================================================================
---- kate/utils/kateautoindent.cpp (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/utils/kateautoindent.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -204,13 +204,26 @@
- if (line <= 0)
- return;
-
-- KateTextLine::Ptr textline = doc->plainKateTextLine(line-1);
-+ KateTextLine::Ptr prevTextLine = doc->plainKateTextLine(line-1);
-+ KateTextLine::Ptr textLine = doc->plainKateTextLine(line);
-
- // textline not found, cu
-- if (!textline)
-+ if (!prevTextLine || !textLine)
- return;
-
-- doIndent (line, textline->indentDepth (tabWidth));
-+ const QString previousWhitespace = prevTextLine->leadingWhitespace();
-+
-+ // remove leading whitespace, then insert the leading indentation
-+ doc->editStart ();
-+
-+ if (!keepExtra)
-+ {
-+ const QString currentWhitespace = textLine->leadingWhitespace();
-+ doc->editRemoveText (line, 0, currentWhitespace.length());
-+ }
-+
-+ doc->editInsertText (line, 0, previousWhitespace);
-+ doc->editEnd ();
- }
-
- void KateAutoIndent::scriptIndent (KateView *view, const KTextEditor::Cursor &position, QChar typedChar)
-Index: kate/view/kateview.cpp
-===================================================================
---- kate/view/kateview.cpp (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/view/kateview.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -1669,7 +1669,7 @@
- QMutexLocker l(m_doc->smartMutex());
-
- KTextEditor::Range oldSelection = *m_selection;
-- *m_selection = selection;
-+ *m_selection = selection.isEmpty() ? KTextEditor::Range::invalid() : selection;
-
- tagSelection(oldSelection);
-
-@@ -1711,9 +1711,6 @@
-
- bool KateView::selection() const
- {
-- if (m_selection->isEmpty())
-- return false;
--
- if(blockSelection())
- return *m_selection != KateSmartRange::invalid();
- else
-Index: kate/view/kateviewinternal.h
-===================================================================
---- kate/view/kateviewinternal.h (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/view/kateviewinternal.h (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -270,7 +270,6 @@
- KateSmartCursor m_cursor;
- KTextEditor::Cursor m_mouse;
- KTextEditor::Cursor m_displayCursor;
-- int m_cursorX;
-
- bool m_possibleTripleClick;
-
-@@ -360,8 +359,8 @@
- KTextEditor::Cursor toVirtualCursor(const KTextEditor::Cursor& realCursor) const;
-
- // These variable holds the most recent maximum real & visible column number
-- bool m_preserveMaxX;
-- int m_currentMaxX;
-+ bool m_preserveX;
-+ int m_preservedX;
-
- bool m_updatingView;
- int m_wrapChangeViewLine;
-Index: kate/view/kateviewinternal.cpp
-===================================================================
---- kate/view/kateviewinternal.cpp (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/view/kateviewinternal.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -87,8 +87,8 @@
- , m_selectAnchor (-1, -1)
- , m_selectionMode( Default )
- , m_layoutCache(new KateLayoutCache(renderer(), this))
-- , m_preserveMaxX(false)
-- , m_currentMaxX(0)
-+ , m_preserveX(false)
-+ , m_preservedX(0)
- , m_updatingView(true)
- , m_cachedMaxStartPos(-1, -1)
- , m_dragScrollTimer(this)
-@@ -179,7 +179,6 @@
-
- m_displayCursor.setPosition(0, 0);
- m_cursor.setInsertBehavior(KTextEditor::SmartCursor::MoveOnInsert);
-- m_cursorX = 0;
-
- setAcceptDrops( true );
-
-@@ -677,12 +676,12 @@
- }
- }
-
-- if (!m_view->dynWordWrap() && endCol != -1)
-+ if (!m_view->dynWordWrap() && (endCol != -1 || m_view->wrapCursor()))
- {
- QMutexLocker lock(m_doc->smartMutex());
-
- KTextEditor::Cursor rc = toRealCursor(c);
-- int sX = renderer()->cursorToX(cache()->textLayout(rc), rc);
-+ int sX = renderer()->cursorToX(cache()->textLayout(rc), rc, !m_view->wrapCursor());
-
- int sXborder = sX-8;
- if (sXborder < 0)
-@@ -953,12 +952,12 @@
- return *this;
- }
-
-- const bool noWrapCursor = m_vi->view()->blockSelection() || !m_vi->m_view->wrapCursor();
-+ const bool wrapCursor = m_vi->view()->wrapCursor();
- int maxColumn = -1;
- if (n >= 0) {
- for (int i = 0; i < n; i++) {
- if (m_column >= thisLine->length()) {
-- if (!noWrapCursor) {
-+ if (wrapCursor) {
- break;
-
- } else if (m_vi->view()->dynWordWrap()) {
-@@ -1320,10 +1319,7 @@
- KateTextLayout t = cache()->textLayout(realLine, 0);
- Q_ASSERT(t.isValid());
-
-- if (m_currentMaxX > m_cursorX)
-- m_cursorX = m_currentMaxX;
--
-- ret.setColumn(renderer()->xToCursor(t, m_cursorX, !m_view->wrapCursor()).column());
-+ ret.setColumn(renderer()->xToCursor(t, m_preservedX, !m_view->wrapCursor()).column());
- }
-
- return ret;
-@@ -1390,13 +1386,9 @@
- if (keepX) {
- KTextEditor::Cursor realCursor = toRealCursor(virtualCursor);
- KateTextLayout t = cache()->textLayout(realCursor);
-- m_cursorX = renderer()->cursorToX(t, realCursor);
-+ // renderer()->cursorToX(t, realCursor, !m_view->wrapCursor());
-
-- if (m_currentMaxX > m_cursorX) {
-- m_cursorX = m_currentMaxX;
-- }
--
-- realCursor = renderer()->xToCursor(thisViewLine, m_cursorX, !m_view->wrapCursor());
-+ realCursor = renderer()->xToCursor(thisViewLine, m_preservedX, !m_view->wrapCursor());
- ret.setColumn(realCursor.column());
- }
-
-@@ -1457,7 +1449,7 @@
- if (m_displayCursor.line() == 0 && (!m_view->dynWordWrap() || cache()->viewLine(m_cursor) == 0))
- return;
-
-- m_preserveMaxX = true;
-+ m_preserveX = true;
-
- KateTextLayout thisLine = currentLayout();
- // This is not the first line because that is already simplified out above
-@@ -1468,14 +1460,8 @@
- Q_ASSERT(m_cursor.column() >= thisLine.startCol());
- Q_ASSERT(!thisLine.wrap() || m_cursor.column() < thisLine.endCol());
-
-- // Retrieve current cursor x position
-- m_cursorX = renderer()->cursorToX(thisLine, m_cursor);
-+ KTextEditor::Cursor c = renderer()->xToCursor(pRange, m_preservedX, !m_view->wrapCursor());
-
-- if (m_currentMaxX > m_cursorX)
-- m_cursorX = m_currentMaxX;
--
-- KTextEditor::Cursor c = renderer()->xToCursor(pRange, m_cursorX, !m_view->wrapCursor());
--
- updateSelection( c, sel );
- l.unlock();
- updateCursor( c );
-@@ -1493,7 +1479,7 @@
- if ((m_displayCursor.line() >= m_doc->numVisLines() - 1) && (!m_view->dynWordWrap() || cache()->viewLine(m_cursor) == cache()->lastViewLine(m_cursor.line())))
- return;
-
-- m_preserveMaxX = true;
-+ m_preserveX = true;
-
- KateTextLayout thisLine = currentLayout();
- // This is not the last line because that is already simplified out above
-@@ -1504,14 +1490,8 @@
- (m_cursor.column() >= thisLine.startCol()) &&
- (!thisLine.wrap() || m_cursor.column() < thisLine.endCol()));
-
-- // Retrieve current cursor x position
-- m_cursorX = renderer()->cursorToX(thisLine, m_cursor);
-+ KTextEditor::Cursor c = renderer()->xToCursor(nRange, m_preservedX, !m_view->wrapCursor());
-
-- if (m_currentMaxX > m_cursorX)
-- m_cursorX = m_currentMaxX;
--
-- KTextEditor::Cursor c = renderer()->xToCursor(nRange, m_cursorX, !m_view->wrapCursor());
--
- l.unlock();
- updateSelection(c, sel);
- l.unlock();
-@@ -1593,11 +1573,9 @@
- int lineadj = m_minLinesVisible;
-
- int linesToScroll = -qMax( (linesDisplayed() - 1) - lineadj, 0 );
-- m_preserveMaxX = true;
-+ m_preserveX = true;
-
- if (!m_doc->pageUpDownMovesCursor () && !atTop) {
-- m_cursorX = renderer()->cursorToX(currentLayout(), m_cursor);
--
- KTextEditor::Cursor newStartPos = viewLineOffset(startPos(), linesToScroll - 1);
- scrollPos(newStartPos);
-
-@@ -1606,12 +1584,9 @@
-
- KateTextLayout newLine = cache()->textLayout(newPos);
-
-- if (m_currentMaxX> m_cursorX)
-- m_cursorX = m_currentMaxX;
-+ newPos = renderer()->xToCursor(newLine, m_preservedX, !view()->wrapCursor());
-
-- newPos = renderer()->xToCursor(newLine, m_cursorX, !view()->wrapCursor());
--
-- m_preserveMaxX = true;
-+ m_preserveX = true;
- updateSelection( newPos, sel );
- l.unlock();
- updateCursor(newPos);
-@@ -1638,11 +1613,9 @@
- int lineadj = m_minLinesVisible;
-
- int linesToScroll = qMax( (linesDisplayed() - 1) - lineadj, 0 );
-- m_preserveMaxX = true;
-+ m_preserveX = true;
-
- if (!m_doc->pageUpDownMovesCursor () && !atEnd) {
-- m_cursorX = renderer()->cursorToX(currentLayout(), m_cursor);
--
- KTextEditor::Cursor newStartPos = viewLineOffset(startPos(), linesToScroll + 1);
- scrollPos(newStartPos);
-
-@@ -1651,12 +1624,9 @@
-
- KateTextLayout newLine = cache()->textLayout(newPos);
-
-- if (m_currentMaxX> m_cursorX)
-- m_cursorX = m_currentMaxX;
-+ newPos = renderer()->xToCursor(newLine, m_preserveX, !view()->wrapCursor());
-
-- newPos = renderer()->xToCursor(newLine, m_cursorX, !view()->wrapCursor());
--
-- m_preserveMaxX = true;
-+ m_preserveX = true;
- updateSelection( newPos, sel );
- l.unlock();
- updateCursor(newPos);
-@@ -1698,15 +1668,10 @@
- {
- QMutexLocker lock(m_doc->smartMutex());
-
-- m_cursorX = renderer()->cursorToX(currentLayout(), m_cursor);
--
- KTextEditor::Cursor newCursor(0, 0);
-
-- if (m_currentMaxX > m_cursorX)
-- m_cursorX = m_currentMaxX;
-+ newCursor = renderer()->xToCursor(cache()->textLayout(newCursor), m_preserveX, !view()->wrapCursor());
-
-- newCursor = renderer()->xToCursor(cache()->textLayout(newCursor), m_cursorX, !view()->wrapCursor());
--
- updateSelection( newCursor, sel );
- lock.unlock();
- updateCursor( newCursor );
-@@ -1718,11 +1683,8 @@
-
- KTextEditor::Cursor newCursor(m_doc->lastLine(), 0);
-
-- if (m_currentMaxX > m_cursorX)
-- m_cursorX = m_currentMaxX;
-+ newCursor = renderer()->xToCursor(cache()->textLayout(newCursor), m_preserveX, !view()->wrapCursor());
-
-- newCursor = renderer()->xToCursor(cache()->textLayout(newCursor), m_cursorX, !view()->wrapCursor());
--
- updateSelection( newCursor, sel );
- lock.unlock();
- updateCursor( newCursor );
-@@ -1903,12 +1865,6 @@
- m_cursor = newCursor;
- m_displayCursor = toVirtualCursor(m_cursor);
-
-- {
-- QMutexLocker lock(m_doc->smartMutex());
--
-- m_cursorX = renderer()->cursorToX(cache()->textLayout(m_cursor), m_cursor);
-- }
--
- if ( m_view == m_doc->activeView() )
- makeVisible ( m_displayCursor, m_displayCursor.column(), false, center, calledExternally );
-
-@@ -1930,12 +1886,14 @@
- }
-
- // Remember the maximum X position if requested
-- if (m_preserveMaxX)
-- m_preserveMaxX = false;
-- else
-- m_currentMaxX = m_cursorX;
-+ if (m_preserveX)
-+ m_preserveX = false;
-+ else {
-+ QMutexLocker lock(m_doc->smartMutex());
-+ m_preservedX = renderer()->cursorToX(cache()->textLayout(m_cursor), m_cursor, !m_view->wrapCursor());
-+ }
-
-- //kDebug(13030) << "m_currentMaxX: " << m_currentMaxX << " (was "<< oldmaxx << "), m_cursorX: " << m_cursorX;
-+ //kDebug(13030) << "m_preservedX: " << m_preservedX << " (was "<< oldmaxx << "), m_cursorX: " << m_cursorX;
- //kDebug(13030) << "Cursor now located at real " << cursor.line << "," << cursor.col << ", virtual " << m_displayCursor.line << ", " << m_displayCursor.col << "; Top is " << startLine() << ", " << startPos().col;
-
- cursorMoved();
-Index: kate/document/katetextline.cpp
-===================================================================
---- kate/document/katetextline.cpp (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/document/katetextline.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -124,6 +124,14 @@
- return previousNonSpaceChar(m_text.length() - 1);
- }
-
-+QString KateTextLine::leadingWhitespace() const
-+{
-+ if (firstChar() < 0)
-+ return string(0, length());
-+
-+ return string(0, firstChar());
-+}
-+
- int KateTextLine::indentDepth (int tabWidth) const
- {
- int d = 0;
-Index: kate/document/katetextline.h
-===================================================================
---- kate/document/katetextline.h (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kate/document/katetextline.h (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -167,6 +167,8 @@
- inline QString string(int column, int length) const
- { return m_text.mid(column, length); }
-
-+ QString leadingWhitespace() const;
-+
- /**
- * Returns the indentation depth with each tab expanded into \e tabWidth characters.
- */
-Index: kfile/kfilewidget.cpp
-===================================================================
---- kfile/kfilewidget.cpp (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kfile/kfilewidget.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -652,6 +652,7 @@
- d->ops->clearFilter();
- d->filterWidget->setFilter(copy);
- d->ops->setNameFilter(d->filterWidget->currentFilter());
-+ d->ops->updateDir();
- d->hasDefaultFilter = false;
- d->filterWidget->setEditable( true );
-
-Index: kioslave/ftp/ftp.cpp
-===================================================================
---- kioslave/ftp/ftp.cpp (.../tags/KDE/4.3.3/kdelibs) (wersja 1053992)
-+++ kioslave/ftp/ftp.cpp (.../branches/KDE/4.3/kdelibs) (wersja 1053992)
-@@ -2258,7 +2258,7 @@
- {
- // check if destination is ok ...
- KDE_struct_stat buff;
-- bool bDestExists = (KDE::stat( sCopyFile, &buff ) != -1);
-+ const bool bDestExists = (KDE::stat( sCopyFile, &buff ) != -1);
- if(bDestExists)
- { if(S_ISDIR(buff.st_mode))
- {
-@@ -2275,9 +2275,10 @@
- // do we have a ".part" file?
- const QString sPart = sCopyFile + QLatin1String(".part");
- bool bResume = false;
-- bool bPartExists = (KDE::stat( sPart, &buff ) != -1);
-- bool bMarkPartial = config()->readEntry("MarkPartial", true);
-- if(bMarkPartial && bPartExists && buff.st_size > 0)
-+ const bool bPartExists = (KDE::stat( sPart, &buff ) != -1);
-+ const bool bMarkPartial = config()->readEntry("MarkPartial", true);
-+ const QString dest = bMarkPartial ? sPart : sCopyFile;
-+ if (bMarkPartial && bPartExists && buff.st_size > 0)
- { // must not be a folder! please fix a similar bug in kio_file!!
- if(S_ISDIR(buff.st_mode))
- {
-@@ -2292,12 +2293,10 @@
- #endif
- }
-
-- if(bPartExists && !bResume) // get rid of an unwanted ".part" file
-+ if (bPartExists && !bResume) // get rid of an unwanted ".part" file
- QFile::remove(sPart);
-
-- // JPF: in kio_file overwrite disables ".part" operations. I do not believe
-- // JPF: that this is a good behaviour!
-- if(bDestExists) // must delete for overwrite
-+ if (bDestExists) // must delete for overwrite
- QFile::remove(sCopyFile);
-
- // WABA: Make sure that we keep writing permissions ourselves,
-@@ -2310,8 +2309,7 @@
-
- // open the output file ...
- KIO::fileoffset_t hCopyOffset = 0;
-- if(bResume)
-- {
-+ if (bResume) {
- iCopyFile = KDE::open( sPart, O_RDWR ); // append if resuming
- hCopyOffset = KDE_lseek(iCopyFile, 0, SEEK_END);
- if(hCopyOffset < 0)
-@@ -2321,8 +2319,9 @@
- }
- kDebug(7102) << "copy: resuming at " << hCopyOffset;
- }
-- else
-- iCopyFile = KDE::open(sPart, O_CREAT | O_TRUNC | O_WRONLY, initialMode);
-+ else {
-+ iCopyFile = KDE::open(dest, O_CREAT | O_TRUNC | O_WRONLY, initialMode);
-+ }
<<Diff was trimmed, longer than 597 lines>>
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/kde4-kdelibs/kde4-kdelibs-branch.diff?r1=1.16&r2=1.17&f=u
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/kde4-kdelibs/kde4-kdelibs.spec?r1=1.174&r2=1.175&f=u
More information about the pld-cvs-commit
mailing list