Esempio n. 1
0
        /// <summary>
        /// Determines if the item should be processed.
        /// </summary>
        /// <param name="argument">The event argument.</param>
        /// <returns>true if the item should be processed; otherwise false.</returns>
        private void CanContinueProcessing(object argument)
        {
            CanContinueProcessingEventArgs arg = argument as CanContinueProcessingEventArgs;
            CacheRequest request    = arg.Request;
            bool         canProcess = true;

            // Is it in the edit cache?
            if (canProcess)
            {
                if (editCache.ContainsKey(request.Guid))
                {
                    canProcess = false;
                }
            }

            // Was the item was updated by the UI thread?
            if (canProcess)
            {
                if (mImageListView != null && !mImageListView.IsItemDirty(request.Guid))
                {
                    canProcess = false;
                }
            }

            arg.ContinueProcessing = canProcess;
        }