コード例 #1
0
 public LocationsForm(LocationGetter locationGetter, MovieGetter movieGetter)
 {
     Cursor = Cursors.WaitCursor;
     InitializeComponent();
     _locationAdder  = new LocationAdder();
     _locationGetter = locationGetter;
     _movieGetter    = movieGetter;
     RefreshData();
     Cursor = Cursors.Default;
 }
コード例 #2
0
        public AddUpdateLocationForm(Location location, LocationGetter locationGetter, LocationAdder locationAdder)
        {
            InitializeComponent();
            _location        = location;
            _locationGetter  = locationGetter;
            _locationAdder   = locationAdder;
            _locationUpdater = new LocationUpdater();
            locationBindingSource.DataSource = _location;

            if (_location.IsNew)
            {
                Text = "Add Location";
            }
            else
            {
                Text = _location.Description;
            }
        }