I need to develop a Chrome Packaged App that will work as a UI for a console application.
For this I need to find a way to be able to execute that console application inside my Packaged App and read it's outputs.
This is a simple task to do in another platforms such as .NET (which I use nowadays).
I've googled everywhere and searched here on Stackoverflow, but I can't seem to find anything related.
The only interoperability I found is NPAPI, (which is about to be discontinuead). So...
Does anyone have a knowledge about this and could give an example or documentarion on how to achieve it?
Thanks!
There's a feature as part of Chrome extensions that might suit you needs called native messaging.
http://developer.chrome.com/extensions/messaging.html#native-messaging-client
Related
I am new to chrome extension development.
I am trying to make an extension for recording screens and audio.
I searched a lot, and looked into some existing extensions like "MediaCore Capture" and "ScreenCastify". It seems they are using some NaCl (Native Client libraries).
I tried debugging but I am not sure what exactly flow they are using..
Then I came across a github repository "https://github.com/aaerox/inspire/" There I found some same sort of code..
I found some nexe and pnexe files also...
On more debugging "MediaCore Capture" code, I found it is also using some nexe.. which I now understand is some compiled native code...
Can anyone help how these can used ?
Or is there anything else that I can use for my extension..
I tried using ffmpeg_asm but it was very slow in merging audio and video streams.. so I am looking into some faster solution.
Is it possible to write a Chrome Extension that will interact with a Native Client application?
I use Irssi through the NaCl Secure Shell application, and I would like to write an extension that simply looks for plain URLs and makes them clickable links.
I'm seeing some strange behavior with extensions and NaCl applications, so I wanted to know if this is something that is even possible.
Additionally, if anyone has a more elegant solution to this, please don't hesitate to let me know.
Thanks!
The fact that the NaCl Secure Shell app uses Native Client under the hood shouldn't matter; the page is rendered using standard HTML.
The documentation for Chrome Extensions here says you should be able to inject content scripts into pages with the chrome-extension scheme. I tried it, but it doesn't work. It seems the documentation is incorrect. See http://crbug.com/153245.
As far as I can tell, it is not possible to modify an extension this way. It is possible to communicate with other extensions/apps (see here), but it seems that the application must expose an API to communicate with.
Secure Shell supports clicking links now via Ctrl+Click. it will support OSC+8 in a future release.
I'm making a sort of batch processing application with Flex and AIR and I want to illustrate the progress of the batch. I'm using mx:ProgressBar, but this is not enough for me, I want to see the progress in the Windows superbar, pretty much similar to when I'm copying files.
The only thing I found is this native extension, but i don't want to use native extensions.
Does AIR provide any API for this?
Since you're trying to access native functionality, you will have to use native extensions. There's no way around it. commented by RIAStar.
For the sake of testing, knowing that I am running from Visual Studio would be nice. I could see if the debugger is attached, but that is not sufficient if I am running with CTRL+F5.
Here's how to see if the debugger is attached:
if (Debugger.IsAttached) Foo();
But my question is, I wonder if there is a way to ask if the current app is from the Store. So, I thought about install folder, but they are identical. Then I thought about this:
Windows.ApplicationModel.Package.Current.Id;
But this appears to be completely implemented even for apps that are being debugged. So, I am stumped. Does anyone know if we can determine if the app is from the Store?
While certainly not the most elegant solution and there's probably a better one, you can check Package.Current.InstalledLocation.Path
If you are running a debug build developed on your local machine and not side loaded, you'll have /debug/ in your folder path.
In Windows 10 apps (this also should be available in 8.1), you can check the IsDevelopmentMode property on the current package.
Package.Current.IsDevelopmentMode
That should tell you whether the package was installed in development mode (which I believe is synonymous with 'side-loaded').
See https://msdn.microsoft.com/en-us/library/windows/apps/windows.applicationmodel.package.isdevelopmentmode.aspx
for more information.
I'm not finding a way to do this in the chrome.* API or even the experimental. It doesn't run through wscript so
ActiveXObject("Shell.Application") isn't allowed.
I fear that my only option is to build a dll with NPAPI but I wanted to see if there was a simpler way.
To update this for a fellow wary lonesome traveler, even NPAPI is deprecated and being phased out. One of the alternatives mentioned in the NPAPI decprecation blog post that looks suitable for this type of problem (and pretty nifty really) is the Native Messaging API.
If you want to do anything Natively, you need to use NPAPI. That allows you to run code outside the sandbox for your extensions.
http://code.google.com/chrome/extensions/npapi.html
Alternatively, you might want to have two applications:
a "client" that works within a chrome extension and
a "local server" where the actual command is executed.
Whenever the extension needs to execute a command, it can connect to the local server via tcp connection.