aboutsummaryrefslogtreecommitdiff
path: root/src-qt5/core/libLumina/RootWindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src-qt5/core/libLumina/RootWindow.cpp')
-rw-r--r--src-qt5/core/libLumina/RootWindow.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src-qt5/core/libLumina/RootWindow.cpp b/src-qt5/core/libLumina/RootWindow.cpp
index b1f740d3..2586ccc2 100644
--- a/src-qt5/core/libLumina/RootWindow.cpp
+++ b/src-qt5/core/libLumina/RootWindow.cpp
@@ -51,7 +51,7 @@ void RootWindow::updateScreenPixmap(screeninfo *info){
QPixmap raw(info->file); //load the image from file
//Now apply the proper aspect ratio as needed
if(info->scale == RootWindow::Stretch || info->scale == RootWindow::Full || info->scale == RootWindow::Fit){
- Qt::AspectRatioMode armode = Qt::KeepAspectRatio;
+ Qt::AspectRatioMode armode = Qt::KeepAspectRatio;
if(info->scale == RootWindow::Stretch ){ armode = Qt::IgnoreAspectRatio; }
else if(info->scale == RootWindow::Full ){ armode = Qt::KeepAspectRatioByExpanding; }
if(raw.height()!=info->area.height() && raw.width() !=info->area.width()){
@@ -60,16 +60,16 @@ void RootWindow::updateScreenPixmap(screeninfo *info){
}
//Now calculate offset and draw width/height
QRect drawRect(0,0, raw.width(), raw.height());
- if(info->scale == RootWindow::Full ){
+ if(info->scale == RootWindow::Full ){
drawRect.moveTo( (info->area.width() - raw.width())/2, (info->area.height() - raw.height())/2 );
}else if(info->scale == RootWindow::Fit ){
- drawRect.moveTo( (info->area.width() - raw.width())/2, (info->area.height() - raw.height())/2 );
+ drawRect.moveTo( (info->area.width() - raw.width())/2, (info->area.height() - raw.height())/2 );
}else if(info->scale == RootWindow::Center ){
- drawRect.moveTo( (info->area.width() - raw.width())/2, (info->area.height() - raw.height())/2 );
+ drawRect.moveTo( (info->area.width() - raw.width())/2, (info->area.height() - raw.height())/2 );
}else if(info->scale == RootWindow::Tile ){
//Draw the entire area - no offset
drawRect.setHeight(info->area.height());
- drawRect.setWidth(info->area.width());
+ drawRect.setWidth(info->area.width());
}else if(info->scale == RootWindow::BottomLeft ){
drawRect.moveTo( 0 , info->area.height() - raw.height() );
}else if(info->scale == RootWindow::BottomRight ){
@@ -138,7 +138,7 @@ void RootWindow::ResizeRoot(){
void RootWindow::ChangeWallpaper(QString id, RootWindow::ScaleType scale, QString file){
bool found = false;
for(int i=0; i<WALLPAPERS.length() && !found; i++){
- if(WALLPAPERS[i].id == id){
+ if(WALLPAPERS[i].id == id){
WALLPAPERS[i].scale = scale;
WALLPAPERS[i].file = file;
updateScreenPixmap(&WALLPAPERS[i]);
@@ -169,7 +169,7 @@ void RootWindow::ChangeWallpaper(QString id, RootWindow::ScaleType scale, QStrin
void RootWindow::NewWindow(NativeWindow *win){
RootSubWindow *subwin = 0;
for(int i=0; i<WINDOWS.length() && subwin==0; i++){
- if(WINDOWS[i]->id() == win->id()){ subwin = WINDOWS[i]; }
+ if(WINDOWS[i]->id() == win->id()){ subwin = WINDOWS[i]; }
}
if(subwin==0){
subwin = new RootSubWindow(this, win);
@@ -181,7 +181,7 @@ void RootWindow::NewWindow(NativeWindow *win){
void RootWindow::CloseWindow(WId win){
for(int i=0; i<WINDOWS.length(); i++){
- if(WINDOWS[i]->id() == win){ WINDOWS.takeAt(i)->clientClosed(); break; }
+ if(WINDOWS[i]->id() == win){ WINDOWS.takeAt(i)->clientClosed(); break; }
}
}
bgstack15