public Gallery Connect() { //System.Console.WriteLine ("GalleryAccount.Connect()"); Gallery gal = null; if (Version == GalleryVersion.VersionUnknown) { this.Version = Gallery.DetectGalleryVersion(Url); } if (Version == GalleryVersion.Version1) { gal = new Gallery1(url, url); } else if (Version == GalleryVersion.Version2) { gal = new Gallery2(url, url); } else { throw new GalleryException(Catalog.GetString("Cannot connect to a Gallery for which the version is unknown.\nPlease check that you have Remote plugin 1.0.8 or later")); } Log.Debug("Gallery created: " + gal); gal.Login(username, password); Gallery = gal; connected = true; Gallery.expect_continue = Preferences.Get <bool> (LIGHTTPD_WORKAROUND_KEY); return(Gallery); }
public Gallery Connect() { //System.Console.WriteLine ("GalleryAccount.Connect()"); Gallery gal = null; if (version == GalleryVersion.VersionUnknown) this.version = Gallery.DetectGalleryVersion(Url); if (version == GalleryVersion.Version1) { gal = new Gallery1 (url, url); } else if (version == GalleryVersion.Version2) { gal = new Gallery2 (url, url); } else { throw new GalleryException (Catalog.GetString("Cannot connect to a Gallery for which the version is unknown.\nPlease check that you have Remote plugin 1.0.8 or later")); } Log.Debug ("Gallery created: " + gal); gal.Login (username, password); gallery = gal; connected = true; gallery.expect_continue = Preferences.Get<bool> (LIGHTTPD_WORKAROUND_KEY); return gallery; }