예제 #1
0
        public override void OnWindowFocusChanged(bool hasFocus)
        {
            base.OnWindowFocusChanged(hasFocus);
            if (hasFocus)
            {
                SetContentView(Resource.Layout.activity_main);

                FloatingActionButton fab = FindViewById <FloatingActionButton>(Resource.Id.fab);
                fab.Click += FabOnClick;

                eh            = new EmployeesHelper();
                EmployeesList = eh.GetEmployees();
                var list = (ListView)FindViewById(Resource.Id.employeesListView);

                var ListAdapter = new ArrayAdapter <String>(this, Android.Resource.Layout.SimpleListItem1, eh.GetEmployeesAsStrings());
                list.Adapter    = ListAdapter;
                list.ItemClick += EmployeesListView_ItemClick;
            }
        }
예제 #2
0
        public IEnumerable <EmployeeModel> WeatherForecasts(int startDateIndex)
        {
            var eh = new EmployeesHelper("employees.json");

            return(eh.GetEmployees());
        }