From 9627e927fb070f1413daa2c2a59c79fc1465c179 Mon Sep 17 00:00:00 2001 From: RKrom Date: Wed, 19 Sep 2012 12:40:38 +0000 Subject: [PATCH] Fixed icon for Photobucket git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@2061 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4 --- GreenshotPhotobucketPlugin/PhotobucketPlugin.resx | 13 ++++++++++--- GreenshotPhotobucketPlugin/PhotobucketUtils.cs | 10 +++++++--- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/GreenshotPhotobucketPlugin/PhotobucketPlugin.resx b/GreenshotPhotobucketPlugin/PhotobucketPlugin.resx index ebae1258e..1727301b6 100644 --- a/GreenshotPhotobucketPlugin/PhotobucketPlugin.resx +++ b/GreenshotPhotobucketPlugin/PhotobucketPlugin.resx @@ -121,9 +121,16 @@ iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 - YQUAAAAgY0hSTQAAeiYAAICEAAD6AAAAgOgAAHUwAADqYAAAOpgAABdwnLpRPAAAAFJJREFUOE9jFBIS - /M9ACQAZQAlmwKXZL0f6f+cxFTAGsXGpw2kATDOMJtkAmAt6TpHpAmLDBacXGhsb/sMAiE2yF+C6oYxR - A/4PxUCkOB0QmxIB9tCMsK3wUGgAAAAASUVORK5CYII= + YQUAAAIsSURBVDhPjZLfT1JhHMbP39DOUcKy0LpptRi57hC6YToTwzIsl26tm35dJl2oQaiX0axs1ECE + xC1CLHWzBZLVlKy2qDZFsqX/xrl4ep+XaK6rc/GMd9/383nO+x6O0tQdsllcg5vW8/d1a/eYsQiWzsme + BzbF4hoqByKrGHhSgG98xVDI0qGr1LeM6oe8z2DumEDdmZihkKVDV9FOjejmjpgoiMHknkBte1SW7RXr + o5emZbjmrMpVf+mKgmFZcOLyczzOfMfL979w494ylta2kZz/hqm5InJrv3Ez9A59wzkZsnToKpozqPMJ + 4+kiQokCMtl1vMqXUO9+CmtvElMLP+APf5CzTG5DMmTp0FVU511Z8OhFEc7rM3j7ZQcHOytXMLmjUFvC + uDa6iGCkgPznHcmQ5T5dRXUExBUqBZ2355Fe2kTN6agEqqlpi2D69TpS2ZJkyNKhKwvqPDE59PjmkM6X + ZQFfaDW17eKFXoiL8rJkyNL5V7DfMymHzVfTyH/aRsO5BExC2h3OuEeGLJ2/BX79wNlJPEx9xViqiIy4 + wuJHUdIVhyqOznDNGffIkKWjOvziCs1+vaErgWMX4/D6ZuHtn8WVwALerPzEzPKWTHZ1S864R4YsHbqi + 4I5+WHxVvPfu7HGFYRF/JcP1//t06CqafVA/0pOEJo6qtUUNJgLpCFfZ5+gvN/XFcby38tkaCVk6dJXG + 1qDNbL9V0uwDuiaOZCiCpdPYOmL7A+GxSANdcOqRAAAAAElFTkSuQmCC \ No newline at end of file diff --git a/GreenshotPhotobucketPlugin/PhotobucketUtils.cs b/GreenshotPhotobucketPlugin/PhotobucketUtils.cs index 71a33f915..306d630cd 100644 --- a/GreenshotPhotobucketPlugin/PhotobucketUtils.cs +++ b/GreenshotPhotobucketPlugin/PhotobucketUtils.cs @@ -67,7 +67,7 @@ namespace GreenshotPhotobucketPlugin { oAuth.TokenSecret = config.PhotobucketTokenSecret; Dictionary parameters = new Dictionary(); // add album - //parameters.Add("identifier", "Apex75/greenshot"); + parameters.Add("id", "Apex75"); // add type parameters.Add("type", "base64"); // Add image @@ -78,10 +78,14 @@ namespace GreenshotPhotobucketPlugin { } // add filename if (filename != null) { - //parameters.Add("filename", filename); + parameters.Add("filename", filename); } try { - responseString = oAuth.oAuthWebRequest(HTTPMethod.POST, "http://api.photobucket.com/album/greenshot/upload.xml", parameters, null, null); + LOG.DebugFormat("Album info", oAuth.oAuthWebRequest(HTTPMethod.GET, "http://api.photobucket.com/album/Apex75", null, null, null)); + responseString = oAuth.oAuthWebRequest(HTTPMethod.POST, "http://api.photobucket.com/album/!/upload", parameters, null, null); + } catch (Exception ex) { + LOG.Error("Error uploading to Photobucket.", ex); + throw ex; } finally { if (!string.IsNullOrEmpty(oAuth.Token)) { config.PhotobucketToken = oAuth.Token;