Forum Replies Created
-
Yamamoto
KeymasterHere is the update. It will show 4.4.1 at the bottom of Kwik panel
MacOS
https://kwiksher.com/daily/Kwik4_mac_2021_1031.dmgWindows
https://kwiksher.com/daily/Kwik4_win_2021_1031.zipBe sure to check Import Previous Settings and Preferences and uncheck Remove Old Versions. This article describes the detail.
Yamamoto
Keymasterhttp://kwiksher.com/daily/Kwik4_win_2020_0514.zip
http://kwiksher.com/daily/Kwik4_mac_2020_0514.dmgModified: scroll widget for a group
put the scroll back ground and the items in a group.
Please notice the @1x checkbox. It is because of display.contentWidth. If it is unchecked, it is treated as @4x coordinate ( unchecked you need to put display.contentWidth*4 = 1920 = 480*4)
manual checkbox to use the values from the text boxes. If empty, the default values are used.
Either disable the horizontal movement or the vertical movement
P.S. Instead of display.contentWidth/Height, display.viewableContentWidth/Height would work for different sizes of devices.
Yamamoto
KeymasterOK, the listener was an anonymous function. let’s give it a function name to remove it later
local myListener = function(event) print(“event.text”) end -- Remove Runtime:addEventListener( “myEvent”, myListener) -- Add Runtime:removeEventListener( “myEvent”, myListener)
Yamamoto
KeymasterI can show how to add an external code to each image of navigation panel. Maybe dispatching an action instead of jumping to a page.
https://www.kwiksher.com/doc/kwik_tutorial/page_controls/navigation/
Is this something you want? If not, email me a psd file to clarify GUI.
Yamamoto
KeymasterThis is a major bug. I have just fixed it and updated Kwik.
http://kwiksher.com/daily/Kwik4_win_2020_0428.zip
http://kwiksher.com/daily/Kwik4_mac_2020_0428.dmg4.3.2 tmplt 2020.0005
FIX:tmplt layer_drag.lua triggering action on release
FIX:Kwik panel. copy & pasteThank you for reporting the issue.
Yamamoto
KeymasterFixed. The codes of no lock and locked are swapped. It will be migrated into the next build of Kwik
https://github.com/kwiksher/kwik4tmplt/blob/master/components/pageXXX/layer_drag.lua
Thank you for the bug report.
Yamamoto
KeymastermyListener.lua in the page’s external code
—
Runtime:addEventListener( “myEvent”, function(event)
print(“event.text”)
end)
—myDispatcher.lua in the button of overlay
—
Runtime:dispatchEvent({ name=”myEvent”, text=”Changed By dispatchEvent” })
—Alternatively use a global varibale set with Kwik
myListener.lua in the page’ external code
—
Runtime:addEventListener( “enterFrame”, function(event)
print(_K.myVar)
end)
—myDispatcher.lua in the button of overlay
—
_K.myVar = “Changed From Overlay”
—For instance, in an external code, you can access a displayObject with layer.YOUR_LAYER_NAME
if _K.myVar == "Blue" then layer.YOUR_LAYER_NAME:setFillColor(0, 0, 1) -- R, G, B end
You can get a value from Overlay to set it to the function.
Yamamoto
KeymasterA global variable or dispatching an event to the page will work to interact from the overlay page. I will check the behavior today.
Yamamoto
KeymasterI have fixed the bug. Please download the following files from the gitHub. I will include these files to the build of Kwik tomorrow.
– tmplt/commands/kwik/canvasAction.lua
– tmplt/components/pageXXX/layer_canvas.lua
https://github.com/kwiksher/kwik4tmplt/blob/master/commands/kwik/canvasAction.luahttps://github.com/kwiksher/kwik4tmplt/blob/master/components/pageXXX/layer_canvas.lua
Yamamoto
Keymaster>comment out the nativeShowAlert from the page_screenshot_.lua so that no alert will pop up
That’s good workaround. I will revise actionX.lua in gitHub. It is not yet migrated into Kwik.
I found it in Corona source code not handle an error when saving an image to PhotosAlbum
UIImageWriteToSavedPhotosAlbum( image, nil, nil, nil )
Also the following discussion about a plugin to use UIImageWriteToSavedPhotosAlbum. The plugin code looks good.
https://forums.coronalabs.com/topic/58195-uiimagewritetosavedphotosalbum-unable-to-callback-to-lua/
I could use to make a saving screenshot plugin for Kwik or modify directory Corona source. Either way, it takes some time.
Yamamoto
KeymasterLooking at the mac error. It seems reading the manual entry instead of the spritesheet lua generated from Texture packer.
I extracted the spritesheet info from the win code above and pasted it into a new file on Mac. and it worked without an error.
Can I have .kwk file of Mac? I would like to check the path of texture packer file in it.
<replacement id="Rectangle_1"> <name>Rectangle_1</name> <type>Sprite Sheet</type> <layer>Rectangle_1</layer> <file>~/Documents/Kwik/SpriteTest/eye.png</file> <frameWidth>128</frameWidth> <frameHeight>128</frameHeight> <externalFile>~/Documents/Kwik/SpriteTest/sprite_info.lua</externalFile> <exporter>TexturePacker</exporter>
Yamamoto
Keymasterpage_screenshot.lua is updated
Wrong: media.photoLibrary
Correct: media.PhotoLibraryI tested it with iPad but the result is not changed. media.hasSource(media.PhotoLibrary) always return true. There is no way to check user rejected the permission request. Nor no method to know the screenshot file is saved or not.
I will look into Corona’s runtime source codes.
Yamamoto
KeymasterThe first time you run an app after a fresh install, media.hasSource( media.PhotoLibrary ) would always return true. This is by design as iOS permissions have a “not determined” state that they’re initialized to when an app is run the first time.
By returning true that first time, your Lua app could continue to whatever behavior needs permission, and the OS can request that permission when necessary.
-
AuthorPosts