Wirrunna wrote:
> The code that you are referring to is just Jivelite for piCorePlayer is
> it not? The logic as you explained it certainly appears wrong, in which
> case why not try fixing it? There are a bunch of us out here that will
> help test it.
Ok, no C code change required. What about this patch?
Code:
--------------------
diff --git a/share/jive/applets/JogglerSkin/JogglerSkinApplet.lua
b/share/jive/applets/JogglerSkin/JogglerSkinApplet.lua
index 718fd4c..fd049f6 100755
--- a/share/jive/applets/JogglerSkin/JogglerSkinApplet.lua
+++ b/share/jive/applets/JogglerSkin/JogglerSkinApplet.lua
@@ -112,7 +112,6 @@ function param(self)
{
style = 'nowplaying_large_art',
artworkSize = '480x480',
- suppressArtworkPress = true,
titleXofYonly = true,
text = self:string("LARGE_ART_AND_TEXT"),
},
diff --git a/share/jive/applets/NowPlaying/NowPlayingApplet.lua
b/share/jive/applets/NowPlaying/NowPlayingApplet.lua
index e51123b..7c4ca4b 100644
--- a/share/jive/applets/NowPlaying/NowPlayingApplet.lua
+++ b/share/jive/applets/NowPlaying/NowPlayingApplet.lua
@@ -1514,24 +1514,15 @@ function _createUI(self)
self.artwork = Icon("artwork")
- local npartwork = Group('npartwork', {
- artwork = self.artwork,
- })
-
- -- Sometimes we want to have controls overlap the artwork.
Unfortunately it seems
- -- the touch event handler isn't respecting zOrder, always preferring
the artwork.
- -- Allow a NP screensver to disable the touch behaviour on the artwork.
- if self:getSelectedStyleParam('suppressArtworkPress') then
- self.artworkGroup = npartwork
- else
- self.artworkGroup = Button(
- npartwork,
- function()
- Framework:pushAction("go_now_playing")
- return EVENT_CONSUME
- end
- )
- end
+ self.artworkGroup = Button(
+ Group('npartwork', {
+ artwork = self.artwork,
+ }),
+ function()
+ Framework:pushAction("go_now_playing")
+ return EVENT_CONSUME
+ end
+ )
-- Visualizer: Spectrum Visualizer - only load if needed
if self.windowStyle == "nowplaying_spectrum_text" then
diff --git a/share/jive/jive/ui/Window.lua b/share/jive/jive/ui/Window.lua
index e576969..b73171f 100644
--- a/share/jive/jive/ui/Window.lua
+++ b/share/jive/jive/ui/Window.lua
@@ -1866,6 +1866,8 @@ function _event(self, event)
r = self:_eventHandler(event)
else
--handle mouse locally, no need for C optimization on mouse
platforms
+ local topWidget
+
r = self:iterate(
function(widget)
if self._mouseEventFocusWidget == widget or
(not self._mouseEventFocusWidget and widget:mouseInside(event)) then
@@ -1873,7 +1875,8 @@ function _event(self, event)
if rClosure ~= EVENT_UNUSED then
--Consumer of MOUSE_DOWN that
is in mouse bounds will be given mouse event focus
if event:getType() ==
EVENT_MOUSE_DOWN then
-
self:setMouseEventFocusWidget(widget)
+ -- iteration is in
ascending zOrder - we only need the top most (last) item
+ topWidget = widget
end
return rClosure
end
@@ -1882,6 +1885,10 @@ function _event(self, event)
end
)
+ if (topWidget) then
+ self:setMouseEventFocusWidget(topWidget)
+ end
+
if event:getType() == EVENT_MOUSE_UP then
self:setMouseEventFocusWidget(nil)
end
--------------------
Most of this is reverting my previous hack to disable touch on the
artwork. The real change is in Window.lua.
Unfortunately I don't have access to hardware to test this on a real
touch screen for the next two weeks. If somebody was willing and able to
try this out that would be helpful. I won't commit it before I've had a
chance to test it.
Michael
http://www.herger.net/slim-plugins - MusicArtistInfo, MusicInfoSCR
------------------------------------------------------------------------
mherger's Profile: http://forums.slimdevices.com/member.php?userid=50
View this thread: http://forums.slimdevices.com/showthread.php?t=103330
_______________________________________________
unix mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/unix