Issue 236

Contributors

This Week...

Basic drag and drop support enabled for the Places Panel and bookmark synchronization in Dolphin.
Multiple improvements in drawing in Calligra; fullscreen mode in Kexi; configuration dialog added in Words.
Work on backup/restore in KDE-PIM.
Better lyrics scrolling in Amarok.
In QtMobility, Android Bluetooth partial support with socket client and device discovery.
Easier access to common tasks in Marble.

Bug Fixes

Development Tools

Milian Wolff committed changes in [kdevelop/4.3] /cpp/cppduchain:

Fix begin-lookup for auto-type deduction in range-based for loops.

First up, ensure we pick the proper list type by introducing a
virtual ContextBuilder::handleRangeBasedFor that is then overwritten
in the DeclarationBuilder. This way we can ensure that lastType()
actually returns the type we want.

Then, when we don't find a viable begin function in the current
namespace via ADL, fallback to ::std::begin (in accordance to the
spec) and repeat.

This was a "regression" caused by a kdevplatform change (bfb0b798)
Static names must not be used for context identifiers, that will
cause confusion (all the generator contexts were named "<generator>").

The only affected generator is poppler. Note that:
Document has /Encrypt <=iff=> SaveInterface supportsOption(SaveChanges) is false

This patch enforces the following behavior (and warns the user the first time
he edits an annotation).

- If the document has /Encrypt, warn that "Save as" is not available, but it's
possible to export as okular archive. New annotations will be automatically
saved to XML as usual.
Note that the previous patch already made all existing annotations uneditable,
because there's no way to save them.

- If the document has no /Encrypt and there are existing external annotations,
warn that changes won't be saved automatically. The user needs to "Save as" or
changes will be lost.

- If the document has no /Encrypt and there aren't existing external
annotations, don't show any warning. New annotations will be automatically saved
to XML as usual and to file if "Save as" is pressed.

Some of these are actual bugfixes compared to Qt4's QUrl,
others are just "equivalent, both results are correct" (less escaping in Qt5).
A number of issues remain, though, in particular path() being encoded,
in discussion with Thiago.

- remember oldest and newest id for timelines
- wire up loadMore() operation
- add a few d-pointers
- do not removeAllData(), this will need to be fixed for switching
timelines, based on heuristics of serviceUrl user and type.

- Use KTcpSocket::SecureProtocols instead of KTcpSocket:TlsV1 as the default SSL
protocol. This fixes very slow connections to certain sites, e.g. "Search for Jobs"
button @ http://www.suse.com/company/careers/.

- Improve the speed of SSL negotiation by caching and sharing the previous
settings amongst ioslaves when those settings are not the default ones.
That way any ioslave that connects to the same host afterwards does not
have to perform the same expensive SSL negotiation process all over again.

Show video previews according to file content instead of the mimetype-string

Show a video widget depending on the video content instead of the mimetype
string: There are container formats which can be either audios or videos.
Besides, the rmvb video files have a mimetype of
"application/vnd.rn-realmedia", and these files can be recognized as videos
correctly now.

I believe that the old lyrics table structure was more or less a mistake:
TABLE lyrics (
id INTEGER PRIMARY KEY, -- actually never used in code
url VARBINARY(324), -- actually a rpath from urls table
lyrics TEXT
)

Apart from data duplication and non-conformity to the "update anomaly"
requirement of the database design, there was additional problem that rpath
itself is not unique. The (deviceId, rpath) is.

with an effort to transition existing entries. The transition of 5000
lyrics entries takes 16s on my 2.5 GHz Core i5 (one core used), so it
should be acceptable.

This is the first time I'm changing db structure, I'd be glad to
receive thorough review, namely of the update13to14() method and
especially the duplicate-removing query. This is critical because
database-corrupting fault would leave many Amarok users in a state
where they would need to drop their database to make Amarok working
again.

ChangeLog of the unrelated iPod fix is updated because DB_VERSION bump
triggers full collection rescan as far as it is documented.

Games

AI was asked twice which tile to discard. This only matters since recently
because since then the random generator is used when two tiles have the same
uselessness. But we want the random generator to be called exactly with the
same order/frequency for all modes (nogui, gui, autoplay) so we can
easier reproduce bugs.

Features

Development Tools

Socket in client mode and device discovery is implemented.
Server socket is feasible and can be added later.
Some of the Qt Bluetooth API's cannot be ported because
Android Bluetooth API is a subset.
Other parts (Service discovery, L2CAP, Channel number, etc) are not
available on Android.

The dropping has not been implemented yet, however in the context of
this step the creating of the drag-pixmap is now forwarded to
the item-widgets. This allows creating some optimized dragging-pixmaps
e.g. for the details-view, where only the name and icon should
be provided as drag-pixmap.

The new exception is not actually thrown yet, but this commit provides
support for handling such an exception, using the following guideline:

* Any exceptions used never cross the API. i.e. client code can be
assured that the underlying library code will not throw any exceptions
when called through the public API. It is simply an implementation
aid.
* If Private::CacheLocker succeeds, it means both d and d->shm are
valid.
* The d-pointer is not necessarily set now, as constructing Private and
mapping shared memory will involve sanity checking the cache as it is
loaded. This affects code using the d-pointer or d->shm without the
CacheLocker.
* Private::CacheLocker itself must still be usable if the d-pointer is
not set, in addition to its existing ability to handle d->shm not
being set.

For just evaluating code changes it might be easiest to use "git diff
-b", which ignores whitespace (there are significant whitespace changes
from adding try{}/catch{} blocks).

Optimization

Development Tools

Perl seems to assume that a lowercase function name that is not *known*
to be a function defined in the current package might be a filehandle or
some kind of other future reserved word.

e.g. with "print foo ($message)"

Perl thinks you're trying to send $message to the filehandle foo if foo
wasn't defined in the current package (even if it's imported from
another module).

To fix this we make the function start with a capital letter (to fix the
potential reserved word warning from the last commit changing colorizer
name), and always reference the full package when using the subroutine
from outside of ksb::Debug.

Educational

Sebastian Gottfried committed changes in [ktouch/next] /:

core: DataAccess refactoring

Now the methods of DataAccess operate on entity classes instead of
creating new ones. Object creation is handled in QML now. This fixes
also various memory leaks, for instance, if the keyboard layout did
change, the old Course objects didn't get deleted. This now handled
automatically by the garbage collection of QML.

This fixes jobtest with Qt5 (difference in QDateTime serialization), but
more generally it will allow BIC changes in SlaveBase, as well as
not crashing due to kdeinit4 or kded4 loading KF5/Qt5 modules, etc.

This is the start of an effort to make all of the test code of the
chart shape follow the Calligra coding standards. A similar effort
for the main code was finished before the start of the GSoC period.

11:07:19 < deevad> Hey, I polishing my brush presets, and I figure I never really understand what stand for 'use curve' or 'use same curve' ( 'use curve = ok it's obvious' ) but ...'use same curves' ... same as what ? thanks for
answer :)
11:09:24 < boud> deevad: iirc, plassy added those options
11:09:50 < boud> I need to check the commit log to see what they are supposed to do :-)
11:10:11 < boud> use the same curve, I think means, use this curve for both opacity and flow
11:10:40 < boud> oh, wait - no
11:11:14 < boud> it means do you want to use one curve for all dynamics sensors, or different curves for different sensors
11:11:32 < deevad> oohohhhh ; now it makes sens
11:11:52 < deevad> thanks boud. Cool, more complex possiblities :)
11:12:09 * deevad back tweaking for the perfect brush
11:12:39 < boud> i'll add a tooltip
11:13:08 < deevad> good idea if it's not a big job to do :)

don't save 0 width or height shapes as "nanpt". Somehow the xls filter sometimes (incorrectly) generates empty path shapes with zero size, and while that is of course meaningless it shouldn't result in invalid odf.

Games

The words are loaded in English, if there is nothing set yet. This is suboptimal
for a non-English speaker since the user needs to change the language manually
at least once, even if the information can be get from the system language. If
the words are not translated (kvtml files) in the system language, English is
used as a fallback.