private static bool ImportWithMOGAssetImporter()
        {
            guiAssetImportCheck check = new guiAssetImportCheck();

            if (check.CheckImportAssetNames(mInvalidAssetNames, ref mNewAssetNames, ref mNewAssetProperties))
            {
                ProgressDialog progress = new ProgressDialog("Importing Assets", "Please wait while assets are imported...", ImportAsset_Worker, null, true);
                progress.ShowDialog(MogMainForm.MainApp);
            }

            return(true);
        }
        public static bool ImportAsOne(string[] sourceFilenames, bool looseFileMatching)
        {
            if (sourceFilenames.Length > 0)
            {
                ArrayList propertiesList = new ArrayList();

                List <object> args = new List <object>();
                args.Add(looseFileMatching);
                args.Add(sourceFilenames);

                ProgressDialog progress = new ProgressDialog("Importing asset as single asset", "Please wait while MOG imports the asset.", ImportAsOne_Worker, args, true);
                if (progress.ShowDialog(MogMainForm.MainApp) == DialogResult.OK)
                {
                    ArrayList assetNames = progress.WorkerResult as ArrayList;
                    string    theOneName = "";

                    // Check if we failed to find a single match?
                    if (assetNames.Count == 1)
                    {
                        MOG_Filename assetName = assetNames[0] as MOG_Filename;
                        theOneName = assetName.GetAssetFullName();
                    }
                    else
                    {
                        //None of these files appear to be in the repository already, so we're going to have to do things the hard way
                        guiAssetImportCheck check = new guiAssetImportCheck();
                        check.CheckImportAssetName(sourceFilenames[0], ref theOneName, ref propertiesList, assetNames);
                    }

                    // Make sure we found theOneName
                    if (!string.IsNullOrEmpty(theOneName))
                    {
                        args = new List <object>();
                        args.Add(theOneName);
                        args.Add(sourceFilenames);
                        args.Add(propertiesList);

                        ProgressDialog creationProgress = new ProgressDialog("Creating Asset", "IMPORTING ASSET: " + theOneName + " with " + sourceFilenames.Length + " files", CreateSingleAsset_Worker, args, false);
                        creationProgress.ShowDialog(MogMainForm.MainApp);

                        return(true);
                    }
                }
            }

            return(false);
        }