예제 #1
0
        private void UpdateNumberOfPhotos()
        {
            Roll [] selected_rolls = SelectedRolls();
            uint    sum            = 0;

            if (selected_rolls != null)
            {
                foreach (Roll roll in selected_rolls)
                {
                    sum = sum + rollstore.PhotosInRoll(roll);
                }
            }
            photos_in_selected_rolls.Text = sum.ToString();
        }
예제 #2
0
        void CreateRolls(Roll [] rolls)
        {
            if (rolls == null)
            {
                rolls = from_db.Rolls.GetRolls();
            }
            RollStore from_store = from_db.Rolls;
            RollStore to_store   = to_db.Rolls;

            foreach (Roll roll in rolls)
            {
                if (from_store.PhotosInRoll(roll) == 0)
                {
                    continue;
                }
                roll_map [roll.Id] = (to_store.Create(roll.Time).Id);
            }
        }