Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

imlement adb wait-for-device event #29

Closed
camalot opened this issue May 19, 2016 · 1 comment
Closed

imlement adb wait-for-device event #29

camalot opened this issue May 19, 2016 · 1 comment
Labels

Comments

@camalot
Copy link
Owner

camalot commented May 19, 2016

Original Bug on CodePlex

I want to create method that will be called when i connect the device.

I saw the DeviceConnected event, but i down't know how to use it.

Some one can post some example how to do this?

@camalot
Copy link
Owner Author

camalot commented May 19, 2016

jnoordam wrote Mar 10, 2015 at 7:44 AM

AndroidDebugBridge adb = AndroidDebugBridge.CreateBridge(adbPath, false);
adb.DeviceConnected += DeviceConnect;
adb.DeviceDisconnected += DeviceDisconnect; 

function signatures 
public void DeviceConnect(object sender, DeviceEventArgs deviceEventArgs)
{
// your connect code here
} 


public void DeviceDisconnect(object sender, DeviceEventArgs deviceEventArgs)
{
// your disconnect code here
}

@camalot camalot closed this as completed May 19, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant