Changing Taskbar menu icon in nodewebkit app dynamically - notifications

I am working on a nodewebkit app. Looking for a functionality where in I can change task-bar icon of app to notify users, similar to what Skype does when a new message is received by user.
Is there any way it can be done in Nodewebkit?
Initially I tried changing window.icon in package.json file, but then I came to know that it is used only once, i.e. on app load. So that did not work.
Anything else I can try?
Thanks in advance

Window.requestAttention(Boolean attention) is what I was looking for.
It worked for me.
Thanks to Dhiraj, It gave me an additional feature for icon.

Related

How to detect a screenshot in a RN application?

I'm having some problem about a screenshot-detector in an application.
I'm using EXPO, but I've no idea about how can I detect a screenshot.
Suppose that I've a profile screen. Each user has a profile page, I want to detect when another user does a screenshot on the screen.
My problem is: how can I detect this? I readed about the gesture here, but it didn't help me. With the gestures I can detect, instead, the scroll in a page, the location x and location y.
I readed also this answer, but about the event touchesCancelled:withEvent:touchesCancelled:withEvent: I have not found anything in React Native docs (and also EXPO docs).
So: which is the idea behind a screenshot detector? Thanks for your help!
You can't do it without detaching EXPO. There is already a feature request for that.
If you decide to detach EXPO, react-native-screenshot-detector might be helpful. The solution is very similar to the one from the linked question.
Currently with expo there is no way to do that, But if you detach you can use this package it supports android&ios screenshot detecting react-native-detector

Firebase Authentication Sign in Providers Not Enabling

I'm getting started with Firebase and I want to enable one of the authentication services, but the little slider won't turn on.
I'm assuming maybe I'm missing some information but it doesn't tell me anything.
They just recently revamped their entire setup... anyone else struggling to enable any of these?
Success. The slider UI component only works as a button. I was dragging it repeatedly and it wouldn't snap on. Probably a bug. Funny.

how to navigate to settings in android emulator using robotium?

I am a newbie for Robotium and till then I managed to learn a lot by directly writing test cases for public websites and sorted out several issues from answers in stackoverflow. now, I seemed to hit the wall at this (probably)trivial problem.
I would like to navigate to 'Settings' icon which is inside 'Apps' menu of the android emulator using some sort of 'robotium-solo' method.
This is my failed attempt:
solo.sendKey(KeyEvent.KEYCODE_HOME);
//solo.clickOnImageButton(2); // no success!
//solo.clickOnActionBarItem(2); // no success!
solo.clickOnText("Settings");
solo.clickOnText("Music");
I checked for any KEYCODE_var for home screen 'app' icon but couldn't find one.
There is no useful log message in DDMS to figure out the starting activity when clicked/tapped on that button.s
Please guide me whether my approach is any good and help me with an answer. Thanks.
you can check with getCurrentViews() and have the list of views displayed before clicking the menu button and after clicking the menu button.By comparing them you can get the view of the new views displayed (i.e. settings button).
After getting the view,you can go with solo.clickOnView(ViewNameObtained);
This will solve your problem for sure.
As far as I know, navigating to settings is not possible with robotium. Even if you would be able to go there you cannot perform any other action as Settings are not port of your application. Android Instrumentation allows performing actions only within one package and robotium is only wrapper for that, so it's not able to click outside your application as well.
You can use UI Automator for that.

Facebook login button showing "Undefined" instead of "Login"

The facebook login button implemented in my website was showing the text as "undefined" instead of "Login" in firefox latest version in Windows 7. So to fix that i went to get the latest code from the Plugin page at https://developers.facebook.com/docs/reference/plugins/login/.
Its showing "undefined" in the preview button also. What should be done to get it fixed?
I am ready to use the latest code given but it looks like a problem with facebook JS to me.
Sorry! I don't have enough rep to post an image :P
I reported it to fb and referenced Ravi's screenshot. Here's my bug report, if you want to subscribe -
https://developers.facebook.com/bugs/383067995106570
This problem once frustrated me and i searched for the solution in many sites. I find one site to be very helpful for me as my problem is solved and solution is easy to understand. so i am sharing with you guys. just go to www.facebookloginhelp.net and get your problem solved.

Forced to switch from iframe to SDK for share buttons

I was using an iframe share button solution to be able to share products or posts on facebook. I used this systeme wich worked great on about 10 different websites but this week, they all ended up no working.
I read I should get an appId for each website and use Asynchroneous SDK, which I did, and followed steps to get it to work:
Load the SDK with appId authentification.
Load jQuery if needed (some buttons require it).
Add button code were desired.
I can see the SDK is loaded in <div id="fb-root"></div> but the share button never appears on the page and it is not a layout issue. I have tried several different buttons but they all seam to never make it to the user.
I read a lot of posts about the issue but each one was magically solved on Jully 22nd... not mine. I need help implementing this first button as I need to fix many websites afterwards. Thx!
When doing a fresh implementation of FB btns I ended up going here:
https://developers.facebook.com/tools/debug
to force FB to crowl the pages I was working on at the moment.
This proved usedful in getting immediate feedback on how things were working out.