-
Notifications
You must be signed in to change notification settings - Fork 12
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Bug Report
Issue is based on this: smartdevicelink/sdl_java_suite#1767
_SoftButtonReplaceOperation's _softButtonCapabilities can be null, and attempting to call _supportsSoftButtonImages can cause an error.
Reproduction Steps
- Set Template that does not support Softbuttons
- In batch update change the layout to one that does support Softbuttons and add Softbuttons in the update
Expected Behavior
Soft buttons appear on screen
Observed Behavior
Crash happens in library due to null access
Browser & Version Information
Tested on 1.5, bug in all environments.
Test Case, Sample Code, and / or Example App
const screenManager = this._sdlManager.getScreenManager();
screenManager.changeLayout(new SDL.rpc.structs.TemplateConfiguration()
.setTemplate(SDL.rpc.enums.PredefinedLayout.LARGE_GRAPHIC_ONLY));
await this._sleep(2500);
const templateConfiguration = new SDL.rpc.structs.TemplateConfiguration()
.setTemplate(SDL.rpc.enums.PredefinedLayout.GRAPHIC_WITH_TEXTBUTTONS);
const softButtonState = new SDL.manager.screen.utils.SoftButtonState("State1", "Text1", null);
const softButtonObject = new SDL.manager.screen.utils.SoftButtonObject("Button1", softButtonState, "State1");
screenManager.beginTransaction();
screenManager.setTextField1("hi");
screenManager.setTextField2("hi as well");
screenManager.setTitle("0uch");
screenManager.setSoftButtonObjects([softButtonObject]);
screenManager.changeLayout(templateConfiguration);
screenManager.commit();
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working