-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WSC Config via SSM, tested on v2.x A11
- Loading branch information
Showing
41 changed files
with
273 additions
and
163 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
using CommunityToolkit.Mvvm.Messaging; | ||
|
||
namespace OEMInfo_MAUI_Sample | ||
{ | ||
public partial class MainPage : ContentPage | ||
{ | ||
int count = 0; | ||
|
||
public MainPage() | ||
{ | ||
InitializeComponent(); | ||
|
||
WeakReferenceMessenger.Default.Register<string>(this, (r, m) => | ||
{ | ||
MainThread.BeginInvokeOnMainThread(() => { | ||
if(m.StartsWith("|")) | ||
entryKB.Text += m.Substring(1); | ||
else | ||
lbDisplayDeviceId.Text = m+"\n"+lbDisplayDeviceId.Text; | ||
}); | ||
}); | ||
} | ||
|
||
public static void ModifyEntry() | ||
{ | ||
Microsoft.Maui.Handlers.EntryHandler.Mapper.AppendToMapping("MyCustomization", (handler, view) => | ||
{ | ||
#if ANDROID | ||
handler.PlatformView.KeyPress += (sender, e) => | ||
{ | ||
try | ||
{ | ||
if (e.KeyCode == Android.Views.Keycode.Tab || e.KeyCode == Android.Views.Keycode.Enter) | ||
{ | ||
e.Handled = true; | ||
|
||
if ((e.KeyCode == Android.Views.Keycode.Enter) && (e.Event.Action == Android.Views.KeyEventActions.Up)) | ||
{ | ||
WeakReferenceMessenger.Default.Send("|<ENTER>"); | ||
((Entry)handler.VirtualView).SendCompleted(); | ||
} | ||
} | ||
else | ||
e.Handled = false; | ||
} | ||
catch (Exception ex) | ||
{ | ||
} | ||
}; | ||
#endif | ||
}); | ||
} | ||
|
||
private void OnCounterClicked(object sender, EventArgs e) | ||
{ | ||
|
||
WeakReferenceMessenger.Default.Send("#WSC"); | ||
count++; | ||
|
||
if (count == 1) | ||
CounterBtn.Text = $"Clicked {count} time"; | ||
else | ||
CounterBtn.Text = $"Clicked {count} times"; | ||
|
||
SemanticScreenReader.Announce(CounterBtn.Text); | ||
} | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"> | ||
<application android:allowBackup="true" android:icon="@mipmap/appicon" android:roundIcon="@mipmap/appicon_round" android:supportsRtl="true"></application> | ||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> | ||
<uses-permission android:name="android.permission.INTERNET" /> | ||
<uses-permission android:name="com.zebra.provider.READ"/> | ||
<uses-permission android:name="com.zebra.securestoragemanager.securecontentprovider.PERMISSION.WRITE"/> | ||
<uses-permission android:name="com.zebra.securestoragemanager.securecontentprovider.PERMISSION.READ"/> | ||
|
||
|
||
<queries> | ||
<package android:name="com.zebra.zebracontentprovider" /> | ||
<package android:name="com.zebra.workstationconnect.release" /> | ||
|
||
<provider android:authorities="com.zebra.securestoragemanager.securecontentprovider"/> | ||
<package android:name="com.zebra.securestoragemanager" /> | ||
</queries> | ||
|
||
</manifest> |
Oops, something went wrong.