Skip to content

Commit 717356a

Browse files
committed
Merge branch 'master' of https://github.com/rogerwang/node-webkit into tests
2 parents c0acec0 + 28ddcf0 commit 717356a

5 files changed

Lines changed: 21 additions & 18 deletions

File tree

src/mac/app-Info.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<key>CFBundlePackageType</key>
2020
<string>APPL</string>
2121
<key>CFBundleShortVersionString</key>
22-
<string>0.6.2</string>
22+
<string>0.6.3</string>
2323
<key>NSPrincipalClass</key>
2424
<string>NSApplication</string>
2525
<key>LSMinimumSystemVersion</key>

src/nw_package.cc

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -367,24 +367,24 @@ bool Package::ExtractPath() {
367367
}
368368

369369
bool Package::ExtractPackage(const FilePath& zip_file, FilePath* where) {
370-
// Auto clean our temporary directory
371-
static scoped_ptr<base::ScopedTempDir> scoped_temp_dir;
372370

371+
if (!scoped_temp_dir_.IsValid()) {
373372
#if defined(OS_WIN)
374-
if (!file_util::CreateNewTempDirectory(L"nw", where)) {
373+
if (!file_util::CreateNewTempDirectory(L"nw", where)) {
375374
#else
376-
if (!file_util::CreateNewTempDirectory("nw", where)) {
375+
if (!file_util::CreateNewTempDirectory("nw", where)) {
377376
#endif
378-
ReportError("Cannot extract package",
379-
"Unable to create temporary directory.");
380-
return false;
381-
}
382-
383-
scoped_temp_dir.reset(new base::ScopedTempDir());
384-
if (!scoped_temp_dir->Set(*where)) {
385-
ReportError("Cannot extract package",
386-
"Unable to set temporary directory.");
387-
return false;
377+
ReportError("Cannot extract package",
378+
"Unable to create temporary directory.");
379+
return false;
380+
}
381+
if (!scoped_temp_dir_.Set(*where)) {
382+
ReportError("Cannot extract package",
383+
"Unable to set temporary directory.");
384+
return false;
385+
}
386+
}else{
387+
*where = scoped_temp_dir_.path();
388388
}
389389

390390
return zip::Unzip(zip_file, *where);

src/nw_package.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
#include "base/basictypes.h"
2525
#include "base/files/file_path.h"
2626
#include "base/memory/scoped_ptr.h"
27+
#include "base/files/scoped_temp_dir.h"
2728

2829
#include <string>
2930

@@ -104,6 +105,9 @@ class Package {
104105
// Stored url for error page.
105106
std::string error_page_url_;
106107

108+
// Auto clean our temporary directory
109+
base::ScopedTempDir scoped_temp_dir_;
110+
107111
DISALLOW_COPY_AND_ASSIGN(Package);
108112
};
109113

src/nw_version.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323

2424
#define NW_MAJOR_VERSION 0
2525
#define NW_MINOR_VERSION 6
26-
#define NW_PATCH_VERSION 2
27-
#define NW_VERSION_IS_RELEASE 1
26+
#define NW_PATCH_VERSION 3
27+
#define NW_VERSION_IS_RELEASE 0
2828

2929
#ifndef NW_STRINGIFY
3030
#define NW_STRINGIFY(n) NW_STRINGIFY_HELPER(n)

src/shell_browser_context.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,6 @@ class ShellBrowserContext : public BrowserContext {
7777
bool off_the_record_;
7878
bool ignore_certificate_errors_;
7979
nw::Package* package_;
80-
base::ScopedTempDir testing_path_;
8180
FilePath path_;
8281
scoped_ptr<ShellResourceContext> resource_context_;
8382
scoped_refptr<ShellDownloadManagerDelegate> download_manager_delegate_;

0 commit comments

Comments
 (0)