Beispiel #1
0
		public Dash(LexEntryRepository RecordListManager, ICurrentWorkTask currentWorkTaskProvider)//, UserSettingsForTask userSettings)
		{
			_oldFlowWidth = 0;
			_lexEntryRepository = RecordListManager;
			_currentWorkTaskProvider = currentWorkTaskProvider;
			InitializeContextMenu();
			Initialize();
		}
Beispiel #2
0
 public Dash(LexEntryRepository RecordListManager, ICurrentWorkTask currentWorkTaskProvider)        //, UserSettingsForTask userSettings)
 {
     _buttonRows              = new List <List <DashboardButton> >();
     _oldPanelWidth           = 0;
     _buttonsPerRow           = 0;
     _buttonRowMargin         = new Padding(30, 0, 0, 15);
     _buttonMargin            = new Padding(3);
     _lexEntryRepository      = RecordListManager;
     _currentWorkTaskProvider = currentWorkTaskProvider;
     InitializeContextMenu();
     Initialize();
 }
Beispiel #3
0
		public SampleTaskBuilder(WeSayWordsProject project, ICurrentWorkTask currentWorkTask, IRecordListManager recordListManager)
		{
			_picoContext = CreateContainer();
			_picoContext.RegisterComponentInstance("Project", project);
			_picoContext.RegisterComponentInstance("Current Task Provider", currentWorkTask);
			_picoContext.RegisterComponentInstance("Record List Manager", recordListManager);

			string[] analysisWritingSystemIds = new string[] { project.WritingSystems.AnalysisWritingSystemDefaultId };
			string[] vernacularWritingSystemIds = new string[] {project.WritingSystems.VernacularWritingSystemDefaultId};
			ViewTemplate viewTemplate = new ViewTemplate();
			viewTemplate.Add(new Field(Field.FieldNames.EntryLexicalForm.ToString(), vernacularWritingSystemIds));
			viewTemplate.Add(new Field(Field.FieldNames.SenseGloss .ToString(), analysisWritingSystemIds));
			viewTemplate.Add(new Field(Field.FieldNames.ExampleSentence.ToString(), vernacularWritingSystemIds));
			viewTemplate.Add(new Field(Field.FieldNames.ExampleTranslation.ToString(), analysisWritingSystemIds));
			_picoContext.RegisterComponentInstance("Default Field Inventory", viewTemplate);
		}
Beispiel #4
0
        public SampleTaskBuilder(WeSayWordsProject project, ICurrentWorkTask currentWorkTask, IRecordListManager recordListManager)
        {
            _picoContext = CreateContainer();
            _picoContext.RegisterComponentInstance("Project", project);
            _picoContext.RegisterComponentInstance("Current Task Provider", currentWorkTask);
            _picoContext.RegisterComponentInstance("Record List Manager", recordListManager);

            string[]     analysisWritingSystemIds   = new string[] { project.WritingSystems.AnalysisWritingSystemDefaultId };
            string[]     vernacularWritingSystemIds = new string[] { project.WritingSystems.VernacularWritingSystemDefaultId };
            ViewTemplate viewTemplate = new ViewTemplate();

            viewTemplate.Add(new Field(Field.FieldNames.EntryLexicalForm.ToString(), vernacularWritingSystemIds));
            viewTemplate.Add(new Field(Field.FieldNames.SenseGloss.ToString(), analysisWritingSystemIds));
            viewTemplate.Add(new Field(Field.FieldNames.ExampleSentence.ToString(), vernacularWritingSystemIds));
            viewTemplate.Add(new Field(Field.FieldNames.ExampleTranslation.ToString(), analysisWritingSystemIds));
            _picoContext.RegisterComponentInstance("Default Field Inventory", viewTemplate);
        }
Beispiel #5
0
		public DashboardControl(LexEntryRepository lexEntryRepository,
								ICurrentWorkTask currentWorkTaskProvider)
		{
			if (lexEntryRepository == null)
			{
				throw new ArgumentNullException("lexEntryRepository");
			}
			if (currentWorkTaskProvider == null)
			{
				throw new ArgumentNullException("currentWorkTaskProvider");
			}
			_taskIndicators = new List<TaskIndicator>();
			_lexEntryRepository = lexEntryRepository;
			_currentWorkTaskProvider = currentWorkTaskProvider;

			//InitializeComponent();
			InitializeContextMenu();
		}