Ejemplo n.º 1
0
        public async void LoadDirectoriesToTree()
        {
            DateTime startTime = DateTime.Now; // the old date

            //double start_in_seconds = TimeSpan.FromTicks(startTime.Ticks).TotalSeconds;

            //tool.debug("Loading audio files");
            //tool.debug(" Start Time: "+startTime);
            await LoadAudioFilesAsync();

            //cannot do ui stuff from anothere thread, so for now populate the treeview afterward
            _view.PopulateTree(Nodes);
            CacheNodes();
            if (tool.StringCheck(searchText))
            {
                SearchForText(searchText);
            }

            if (loadID3Tags)
            {
                fileLoader.LoadID3Library();
            }
            DateTime endTime = DateTime.Now;
            // double end_in_seconds = TimeSpan.FromTicks(endTime.Ticks).TotalSeconds;
            //tool.debug("End Time: " + endTime);
            double elapsed_seconds = (endTime - startTime).TotalSeconds;

            tool.debug("elapised time: " + elapsed_seconds);
        }