{
{ setDaemon(true); }
public void run()
{
WeblogAPIException ex = null;
WeblogPost post = new WeblogPost(title, text, sourceURL, sourceTitle, publish);
addProperties(post);
List<Integer> ind = getSelectedBlogIndices();
for (int i : ind)
{
TargetBlog targetBlog = getBlogAt(i);
IWeblogAPI api = targetBlog.getApiType();
post.categories = getCategoriesForBlog(i);
// Perform a call
try
{
api.newPost(targetBlog, post);
} catch (WeblogAPIException e1)
{
ex = e1;
LOG.log(Level.WARNING, e1.getMessage(), e1);
}
if (ex != null) break;
}
// Report the results
final WeblogAPIException err = ex;
SwingUtilities.invokeLater(new Runnable()
{
public void run()
{
enableControls(true);