You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* check isGraphicSupported in SoftButtonManager
* Remove log from testing
* fix formatting
* Unit test updates
* Add unit test to test when graphic is not supported. Align with iOS on uploading graphic when no capability is retrieved
* Fix logic to allow for static images to still be uploaded if dynamic are not supported
* Fix logic in uploading softbuttons, align with iOS
* Revert log back to a warning
* Add unit test
* Refactor isGraphicSupported to isDynamicGraphicSupported
// We only need to pass the first softButtonCapabilities in the array due to the fact that all soft button capabilities are the same (i.e. there is no way to assign a softButtonCapabilities to a specific soft button).
@@ -65,6 +68,18 @@ public void onComplete(boolean success) {
65
68
onFinished();
66
69
}
67
70
});
71
+
} elseif (!supportsDynamicSoftButtonImages()) {
72
+
DebugTool.logInfo(TAG, "Soft button images are not supported. Attempting to send text and static image only soft buttons. If any button does not contain text and/or a static image, no buttons will be sent.");
DebugTool.logError(TAG, "Buttons will not be sent because the module does not support dynamic images and some of the buttons do not have text or static images");
DebugTool.logWarning(TAG, "Attempted to create text and static image only buttons, but some buttons don't support text and have dynamic images, so no soft buttons will be sent.");
273
+
if (completionListener != null) {
274
+
completionListener.onComplete(false);
275
+
}
276
+
return;
277
+
}
278
+
279
+
280
+
if (softButton.getImage() != null && softButton.getImage().getImageType() == ImageType.DYNAMIC) {
281
+
// We should create a new softButtonObject rather than modifying the original one
// Returns text soft buttons representing the current states of the button objects, or returns if _any_ of the buttons' current states are image only buttons.
0 commit comments