Subversion Repositories spk

Rev

Rev 191 | Rev 196 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 191 Rev 192
Line 46... Line 46...
46
		else if ( arg.left(2) == L"--" )
46
		else if ( arg.left(2) == L"--" )
47
		{
47
		{
48
			Utils::WString argSwitch = arg.token(L":", 1).lower();
48
			Utils::WString argSwitch = arg.token(L":", 1).lower();
49
			Utils::WString argSwitchFirst = arg.token(L" ", 1).lower();
49
			Utils::WString argSwitchFirst = arg.token(L" ", 1).lower();
50
			Utils::WString rest = arg.tokens(L":", 2);
50
			Utils::WString rest = arg.tokens(L":", 2);
51
			if ( rest[0] == '"' && rest[rest.length() - 1] != '"' )
51
			if (!rest.empty())
52
			{
52
			{
53
				rest.erase(0, 1);
-
 
54
				while ( i < args->Length )
53
				if (rest[0] == '"' && rest[rest.length() - 1] != '"')
55
				{
54
				{
-
 
55
					rest.erase(0, 1);
-
 
56
					while (i < args->Length)
-
 
57
					{
56
					i++;
58
						i++;
57
					Utils::WString argCheck = _WS(args[i]);
59
						Utils::WString argCheck = _WS(args[i]);
58
					rest += " ";
60
						rest += " ";
59
					rest += argCheck;
61
						rest += argCheck;
60
					if ( argCheck.right(1) == L"\"" )
62
						if (argCheck.right(1) == L"\"")
61
						break;
63
							break;
-
 
64
					}
62
				}
65
				}
-
 
66
 
-
 
67
				if (rest.right(1) == L"\"")
-
 
68
					rest.truncate(rest.length() - 1);
63
			}
69
			}
64
 
-
 
65
			if ( rest.right(1) == L"\"" )
-
 
66
				rest.truncate(rest.length() - 1);
-
 
67
 
-
 
68
			if ( argSwitch == "--dir" && !rest.empty() )
70
			if ( argSwitch == "--dir" && !rest.empty() )
69
			{
71
			{
70
				Utils::String gameName = packages.getGameName(rest.toString());
72
				Utils::String gameName = packages.getGameName(rest.toString());
71
				if ( !gameName.empty() )
73
				if ( !gameName.empty() )
72
					dirList.pushBack(rest.toString(), gameName);
74
					dirList.pushBack(rest.toString(), gameName);