Quantcast
Channel: Andrej Baranovskij Blog
Viewing all articles
Browse latest Browse all 705

Workaround for ADF 12.2.1.1 Match Media Behavior Tag

$
0
0
If you run ADF 12.2.1.1 application with adaptive UI implemented by af:matchMediaBehavior tag (ADF 12.2.1 Responsive UI Improvements), most likely you will face Null Pointer Exception in Match Media Behavior tag class. Apparently af:matchMediaBehavior tag expects default value to be set on UI component. If default value is not set explicitly, it fails to read it and generates exception (this was not the case in ADF 12.2.1).

This example contains three af:matchMediaBehavior tags, properties orientation and styleClass are not set on panel spitter by default:


This leads into Null Pointer exception on runtime:


To fix this, we can set default values for orientation and styleClass explicitly. Propety styleClass can be assigned with empty value, this helps:


UI is loaded this time:


UI is resized on narrow screen - panel splitter orientation is changed:


Download application with workaround for af:matchMediaBehavior - ADFResponsiveUIApp_v2.zip.

Viewing all articles
Browse latest Browse all 705

Trending Articles