[Kde-games-devel] Review Request: KAtomic first run resize bug

Parker Coates parker.coates at gmail.com
Sat May 2 17:21:59 CEST 2009


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.kde.org/r/653/#review1028
-----------------------------------------------------------


That check was most likely added as an optimisation to reduce the number of resizes on startup. Resize events are very expensive for our games as they involve rerendering SVGs.

But obviously showing the wrong size on first run is not worth whatever optimisation (if any) this check adds.

- Parker


On 2009-05-02 07:04:33, Alan Alpert wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://reviewboard.kde.org/r/653/
> -----------------------------------------------------------
> 
> (Updated 2009-05-02 07:04:33)
> 
> 
> Review request for KDE Games.
> 
> 
> Summary
> -------
> 
> When KAtomic is started the background image doesn't fill the window. Note that this is only the first time you start KAtomic so you'll need to delete katomicrc (and it's not guaranteed, but about 90% of my tests without katomicrc had this issue).
> 
> I don't know why it's testing Qt::WA_PendingResizeEvent, which seems to me to be primarily for Qt internal use. The first resize event usually has that attribute, and so the playfield widget isn't sized right (unless another resize event happens, like loading previous geometry from the config file). I placed "&& false" into the condition on line 239 and it always resized correctly, fixing this bug.
> 
> I am working from the assumption that this if statement is not neccessary, as I do not understand it's purpose. This is not necessarily true, and should this if statement be important then a more appropriate fix will be needed.
> 
> 
> Diffs
> -----
> 
>   trunk/KDE/kdegames/katomic/gamewidget.cpp 962418 
> 
> Diff: http://reviewboard.kde.org/r/653/diff
> 
> 
> Testing
> -------
> 
> Bug was successfully reproduced from an initial sighting in KDE 4.2.2. using svn trunk at r962430. The bug seemed resolved over mulitple trials of deleting katomicrc and running the application after the "&& false" was added. The attached patch was then created. It was tested that the attached patch compiles, however running KAtomic was not tested with the below patch (though it shouldn't differ from the case with "&& false" in the condition).
> 
> 
> Screenshots
> -----------
> 
> The undesired behaviour
>   http://reviewboard.kde.org/r/653/s/110/
> 
> 
> Thanks,
> 
> Alan
> 
>



More information about the kde-games-devel mailing list