Heavily reduced idle cpu consumption.

This commit is contained in:
Filippo Scognamiglio 2014-03-30 18:30:35 +02:00
parent 9c83b1d654
commit 34f61cd86a
6 changed files with 13 additions and 5 deletions

View File

@ -37,6 +37,8 @@ Item{
} }
} }
onUpdatedImage: {blurredSource.live = true;livetimer.restart();}
Component.onCompleted: { Component.onCompleted: {
font.pointSize = shadersettings.fontSize; font.pointSize = shadersettings.fontSize;
font.family = shadersettings.font.name; font.family = shadersettings.font.name;
@ -58,6 +60,12 @@ Item{
sourceItem: blurredterminal sourceItem: blurredterminal
recursive: true recursive: true
live: true live: true
Timer{
id: livetimer
running: true
onTriggered: parent.live = false;
}
} }
} }

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE QtCreatorProject> <!DOCTYPE QtCreatorProject>
<!-- Written by QtCreator 3.0.1, 2014-03-27T13:16:23. --> <!-- Written by QtCreator 3.0.1, 2014-03-30T17:53:23. -->
<qtcreator> <qtcreator>
<data> <data>
<variable>ProjectExplorer.Project.ActiveTarget</variable> <variable>ProjectExplorer.Project.ActiveTarget</variable>

View File

@ -121,10 +121,6 @@ ApplicationWindow{
GradientStop{position: 0.7; color: "#00000000"} GradientStop{position: 0.7; color: "#00000000"}
} }
} }
Terminal{
anchors.fill: parent
}
} }
ShaderSettings{ ShaderSettings{

View File

@ -903,6 +903,8 @@ void KTerminalDisplay::updateImage()
delete[] dirtyMask; delete[] dirtyMask;
delete[] disstrU; delete[] disstrU;
//Notify changes to qml
emit updatedImage();
} }
void KTerminalDisplay::setBlinkingCursor(bool blink) void KTerminalDisplay::setBlinkingCursor(bool blink)

View File

@ -404,6 +404,7 @@ signals:
void changedAutoVKB(bool au); void changedAutoVKB(bool au);
void changedAutoFocus(bool au); void changedAutoFocus(bool au);
void updatedImage();
void clicked(); void clicked();
///////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////

View File

@ -110,6 +110,7 @@ Module {
name: "changedSession" name: "changedSession"
Parameter { name: "session"; type: "KSession"; isPointer: true } Parameter { name: "session"; type: "KSession"; isPointer: true }
} }
Signal { name: "updatedImage" }
Method { name: "forcedFocus" } Method { name: "forcedFocus" }
Method { Method {
name: "setColorScheme" name: "setColorScheme"