Quivr / Android-Week-View

Android Week View is an android library to display calendars (week view or day view) within the app. It supports custom styling.
Apache License 2.0
258 stars 64 forks source link

Loading events created from other activity #17

Closed EvanCooper9 closed 8 years ago

EvanCooper9 commented 8 years ago

Hi,

I'm having difficulty loading events through onMonthChange. Specifically, I'm trying to store events created in a previous activity within a Static variable, that is of type List<? extends WeekViewEvent>. This would allow me to create events outside onMonthChange. However, when returning the array in onMonthChange, the application crashes with a java.lang.OutOfMemoryError error.

Using a static variable for storing events before the activity with the WeekView is loaded is my attempt at getting around the fact that we currently can't use bundles to pass WeekViewEvents.

Would you guys say that this is mainly be due to a issue related with the onMonthChange, or a syntax/language error on my side?

Thanks!

EvanCooper9 commented 8 years ago

Nevermind, I've figured out the issue. Silly mistake when creating the events.