Fix dialog state handling.

Convert ApplicationLightPreference into a DialogPreference to correctly
manage the dialog lifecycle, e.g. when rotating the device. Also save
the user-defined color in case the dialog was open.

Change-Id: Ife00e1c4737fbf6710ccdaa1252def00f2831af3
JIRA:CYAN-914
Fix dialog not opening for app-specific notification light settings.

Change-Id: I8e8d098bcc07824803b9e9931595f5c4fdbabb7b