diff options
author | lado <herrlado@gmail.com> | 2013-05-26 22:53:14 +0200 |
---|---|---|
committer | lado <herrlado@gmail.com> | 2013-05-26 22:53:14 +0200 |
commit | 241ae4d10710f825b1cfcc0ccbd48ecdfb7993ba (patch) | |
tree | 2a76342a9e1b733e58f819a133d4e9d7935dc33a | |
parent | e4fe15c33291bb0becd1701d1ea946d2021e424e (diff) | |
download | vdr-manager-241ae4d10710f825b1cfcc0ccbd48ecdfb7993ba.tar.gz vdr-manager-241ae4d10710f825b1cfcc0ccbd48ecdfb7993ba.tar.bz2 |
fIX NPE
-rw-r--r-- | vdrmanager/src/de/bjusystems/vdrmanager/gui/EpgDetailsActivity.java | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/vdrmanager/src/de/bjusystems/vdrmanager/gui/EpgDetailsActivity.java b/vdrmanager/src/de/bjusystems/vdrmanager/gui/EpgDetailsActivity.java index 1762f43..861746c 100644 --- a/vdrmanager/src/de/bjusystems/vdrmanager/gui/EpgDetailsActivity.java +++ b/vdrmanager/src/de/bjusystems/vdrmanager/gui/EpgDetailsActivity.java @@ -476,6 +476,15 @@ public class EpgDetailsActivity extends ICSBaseActivity implements final Event cEvent = epgs.get(pager.getCurrentItem()); + + final Timerable timerable; + + if(cEvent instanceof Timerable){ + timerable = (Timerable)cEvent; + } else { + return; + } + switch (v.getId()) { case R.id.epg_event_livetv: if (cEvent instanceof Recording) { @@ -511,8 +520,7 @@ public class EpgDetailsActivity extends ICSBaseActivity implements public void onClick(DialogInterface dialog, int which) { final Timer t; if (timer == null) { - //t = timerable.createTimer(); - t = null; + t = timerable.createTimer(); } else { t = timer; } |