1
mirror of https://invent.kde.org/network/falkon.git synced 2024-09-21 17:52:10 +02:00

SpeedDial: fixed removing bg image when changing background position

This commit is contained in:
nowrep 2012-04-25 11:20:41 +02:00
parent fa37d1650f
commit bacca991e0
2 changed files with 5 additions and 1 deletions

View File

@ -338,6 +338,7 @@ function sdSizeToggle() {
var check = document.getElementById('SdSizeToggle');
var SdSize = document.getElementById('SdSize');
var SdSizeSl = document.getElementById('sliderValueSd');
SdSize.disabled = (check.checked ? false : true);
SdSize.value = (check.checked ? SdSize.value : 231);
SdSizeSl.innerHTML = (check.checked ? DIAL_WIDTH : 231);
@ -347,9 +348,11 @@ function bgImgUpdate() {
var imgUrl = document.getElementById('BgImgHold').value;
var imgSize = document.getElementById('BgImgSelSiz').value;
var imgThumb = document.getElementById('thumb');
imgThumb.style.backgroundImage = 'url("' + imgUrl + '")';
imgThumb.title = imgUrl.substring(imgUrl.lastIndexOf('/')+1);
imgThumb.style.backgroundSize = imgSize;
document.body.style.backgroundImage = 'url("' + imgUrl + '")';
document.body.style.backgroundSize = imgSize;
}
@ -377,6 +380,7 @@ $(document).ready(function () {
%INITIAL-SCRIPT%
alignPage();
$(window).resize(function() { alignPage(); });
$("div").disableSelection();
$("#quickdial").sortable({

View File

@ -293,7 +293,7 @@ QString SpeedDial::urlFromUserInput(const QString &url)
void SpeedDial::setBackgroundImage(const QString &image)
{
m_backgroundImage = QUrl(image).toEncoded();
m_backgroundImage = image;
}
void SpeedDial::setBackgroundImageSize(const QString &size)