Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
OpenBoard
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lifo
Nicolas Ollinger
OpenBoard
Commits
8c4f8182
Commit
8c4f8182
authored
Jul 31, 2012
by
Aleksei Kanash
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of github.com:Sankore/Sankore-3.1
parents
9ebeb982
de65259b
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
52 additions
and
13 deletions
+52
-13
Sankore_3.1.pro
Sankore_3.1.pro
+1
-1
release.win7.vc9.bat
release.win7.vc9.bat
+22
-3
ubw-main.js
...rces/library/applications/Calculatrice.wgt/js/ubw-main.js
+24
-9
UBFeaturesController.cpp
src/board/UBFeaturesController.cpp
+5
-0
No files found.
Sankore_3.1.pro
View file @
8c4f8182
...
@@ -14,7 +14,7 @@ linux-g++-64 {
...
@@ -14,7 +14,7 @@ linux-g++-64 {
VERSION_MAJ
=
2
VERSION_MAJ
=
2
VERSION_MIN
=
00
VERSION_MIN
=
00
VERSION_TYPE
=
b
#
a
=
alpha
,
b
=
beta
,
r
=
release
,
other
=>
error
VERSION_TYPE
=
b
#
a
=
alpha
,
b
=
beta
,
r
=
release
,
other
=>
error
VERSION_PATCH
=
0
1
VERSION_PATCH
=
0
2
VERSION
=
"$${VERSION_MAJ}.$${VERSION_MIN}.$${VERSION_TYPE}.$${VERSION_PATCH}"
VERSION
=
"$${VERSION_MAJ}.$${VERSION_MIN}.$${VERSION_TYPE}.$${VERSION_PATCH}"
VERSION
=
$$
replace
(
VERSION
,
"\\.r"
,
""
)
VERSION
=
$$
replace
(
VERSION
,
"\\.r"
,
""
)
...
...
release.win7.vc9.bat
View file @
8c4f8182
REM --------------------------------------------------------------------
REM --------------------------------------------------------------------
REM This program is free software: you can redistribute it and/or modify
REM This program is free software: you can redistribute it and/or modify
REM it under the terms of the GNU General Public License as published by
REM it under the terms of the GNU General Public License as published by
REM the Free Software Foundation, either version
3
of the License, or
REM the Free Software Foundation, either version
2
of the License, or
REM (at your option) any later version.
REM (at your option) any later version.
REM
REM
REM This program is distributed in the hope that it will be useful,
REM This program is distributed in the hope that it will be useful,
...
@@ -18,6 +18,7 @@ set QT_BIN=%QT_DIR%\bin
...
@@ -18,6 +18,7 @@ set QT_BIN=%QT_DIR%\bin
set PROGRAMS_FILE_PATH=C:\Program Files
set PROGRAMS_FILE_PATH=C:\Program Files
set SEVEN_ZIP_EXE="%PROGRAMS_FILE_PATH%\7-Zip\7z.exe"
set GIT_BIN=%PROGRAMS_FILE_PATH%\Git\bin
set GIT_BIN=%PROGRAMS_FILE_PATH%\Git\bin
set VS_BIN=%PROGRAMS_FILE_PATH%\Microsoft Visual Studio 9.0\VC\bin
set VS_BIN=%PROGRAMS_FILE_PATH%\Microsoft Visual Studio 9.0\VC\bin
set WIN_SDK_BIN=%PROGRAMS_FILE_PATH%\Microsoft SDKs\Windows\v6.0A\Bin
set WIN_SDK_BIN=%PROGRAMS_FILE_PATH%\Microsoft SDKs\Windows\v6.0A\Bin
...
@@ -37,7 +38,7 @@ REM is correct. This is important because installer
...
@@ -37,7 +38,7 @@ REM is correct. This is important because installer
REM pick up dll from this directory
REM pick up dll from this directory
IF NOT EXIST "%QT_DIR%\lib\QtCore4.dll" GOTO EXIT_WITH_ERROR
IF NOT EXIST "%QT_DIR%\lib\QtCore4.dll" GOTO EXIT_WITH_ERROR
rmdir /S /Q %BUILD_DIR%
REM
rmdir /S /Q %BUILD_DIR%
set EDITION=MNEMIS_EDITION
set EDITION=MNEMIS_EDITION
...
@@ -46,7 +47,9 @@ set EDITION=MNEMIS_EDITION
...
@@ -46,7 +47,9 @@ set EDITION=MNEMIS_EDITION
%LRELEASE% Sankore_3.1.pro
%LRELEASE% Sankore_3.1.pro
%LRELEASE% %BASE_QT_TRANSLATIONS_DIRECTORY%\translations.pro
%LRELEASE% %BASE_QT_TRANSLATIONS_DIRECTORY%\translations.pro
REM set /p VERSION= < build\win32\release\version
set /p VERSION= < build\win32\release\version
REM remove the last character that is a space
set VERSION=%VERSION: =%
REM git rev-list --tags --max-count=1 > tmp
REM git rev-list --tags --max-count=1 > tmp
REM set /p LAST_TAG= < tmp
REM set /p LAST_TAG= < tmp
REM erase tmp
REM erase tmp
...
@@ -78,3 +81,19 @@ set INSTALLER_PATH=.\install\win32\%INSTALLER_NAME%.exe
...
@@ -78,3 +81,19 @@ set INSTALLER_PATH=.\install\win32\%INSTALLER_NAME%.exe
call "%INNO_EXE%" "Sankore 3.1.iss" /F"%INSTALLER_NAME%"
call "%INNO_EXE%" "Sankore 3.1.iss" /F"%INSTALLER_NAME%"
set INSTALL_DIRECTORY=install\win32\
xcopy *.pdf %INSTALL_DIRECTORY%
cd %INSTALL_DIRECTORY%
call %SEVEN_ZIP_EXE% a Open-Sankor_Windows_%VERSION%.zip *.exe *.pdf
cd ..\..\
GOTO END
:EXIT_WITH_ERROR
echo "Error found"
GOTO :EOF
:END
echo "Open-Sankore's build finished"
:EOF
resources/library/applications/Calculatrice.wgt/js/ubw-main.js
View file @
8c4f8182
...
@@ -350,7 +350,6 @@ function init(){
...
@@ -350,7 +350,6 @@ function init(){
function
compute
(){
function
compute
(){
var
result
;
var
result
;
//alert(calc)
if
(
calc
.
length
<=
1
)
if
(
calc
.
length
<=
1
)
result
=
eval
(
calc
);
result
=
eval
(
calc
);
else
{
else
{
...
@@ -362,7 +361,6 @@ function init(){
...
@@ -362,7 +361,6 @@ function init(){
operation
=
(
calc
.
indexOf
(
"+"
,
0
)
!=
-
1
)?
calc
.
charAt
(
calc
.
indexOf
(
"+"
,
0
)):((
calc
.
indexOf
(
"*"
,
0
)
!=
-
1
)?
calc
.
charAt
(
calc
.
indexOf
(
"*"
,
0
)):((
calc
.
indexOf
(
"/"
,
0
)
!=
-
1
)?
calc
.
charAt
(
calc
.
indexOf
(
"/"
,
0
)):((
calc
.
indexOf
(
"-"
,
0
)
!=
-
1
)?
calc
.
charAt
(
calc
.
indexOf
(
"-"
,
0
)):
""
)));
operation
=
(
calc
.
indexOf
(
"+"
,
0
)
!=
-
1
)?
calc
.
charAt
(
calc
.
indexOf
(
"+"
,
0
)):((
calc
.
indexOf
(
"*"
,
0
)
!=
-
1
)?
calc
.
charAt
(
calc
.
indexOf
(
"*"
,
0
)):((
calc
.
indexOf
(
"/"
,
0
)
!=
-
1
)?
calc
.
charAt
(
calc
.
indexOf
(
"/"
,
0
)):((
calc
.
indexOf
(
"-"
,
0
)
!=
-
1
)?
calc
.
charAt
(
calc
.
indexOf
(
"-"
,
0
)):
""
)));
fNumber
=
fMinus
+
calc
.
substring
(
0
,
calc
.
indexOf
(
operation
,
0
));
fNumber
=
fMinus
+
calc
.
substring
(
0
,
calc
.
indexOf
(
operation
,
0
));
lNumber
=
calc
.
substring
(
calc
.
indexOf
(
operation
,
0
)
+
1
,
calc
.
length
);
lNumber
=
calc
.
substring
(
calc
.
indexOf
(
operation
,
0
)
+
1
,
calc
.
length
);
//alert(fNumber + " | " + operation + " | " + lNumber)
result
=
calcIt
(
fNumber
,
operation
,
lNumber
);
result
=
calcIt
(
fNumber
,
operation
,
lNumber
);
}
}
...
@@ -391,10 +389,10 @@ function init(){
...
@@ -391,10 +389,10 @@ function init(){
lCount
=
(
lNumber
.
indexOf
(
"."
,
0
)
!=
-
1
)?
lNumber
.
substring
(
lNumber
.
indexOf
(
"."
,
0
)
+
1
,
lNumber
.
length
):
""
;
lCount
=
(
lNumber
.
indexOf
(
"."
,
0
)
!=
-
1
)?
lNumber
.
substring
(
lNumber
.
indexOf
(
"."
,
0
)
+
1
,
lNumber
.
length
):
""
;
length
=
(
fCount
.
length
>=
lCount
.
length
)?
fCount
.
length
:
lCount
.
length
;
length
=
(
fCount
.
length
>=
lCount
.
length
)?
fCount
.
length
:
lCount
.
length
;
length
=
Math
.
pow
(
10
,
length
);
length
=
Math
.
pow
(
10
,
length
);
fNumber
=
fNumber
*
length
;
fNumber
=
Math
.
round
(
fNumber
*
length
)
;
lNumber
=
lNumber
*
length
;
lNumber
=
Math
.
round
(
lNumber
*
length
)
;
switch
(
operation
){
switch
(
operation
){
case
"+"
:
case
"+"
:
result
=
(
fNumber
+
lNumber
)
/
length
;
result
=
(
fNumber
+
lNumber
)
/
length
;
break
;
break
;
case
"-"
:
case
"-"
:
...
@@ -516,10 +514,27 @@ function init(){
...
@@ -516,10 +514,27 @@ function init(){
displayTrunk
=
displayTrunk
.
substr
(
0
,
displayTrunk
.
length
-
1
);
displayTrunk
=
displayTrunk
.
substr
(
0
,
displayTrunk
.
length
-
1
);
};
};
calc
+=
String
(
char
);
if
(
calc
==
"0"
){
displayTrunk
+=
String
(
char
);
if
(
char
!=
"0"
){
historyTrunk
+=
String
(
char
);
if
(
char
!=
"."
){
lastchar
.
type
=
"Number"
;
calc
=
String
(
char
);
displayTrunk
=
String
(
char
);
historyTrunk
=
String
(
char
);
lastchar
.
type
=
"Number"
;
}
else
{
calc
+=
String
(
char
);
displayTrunk
+=
String
(
char
);
historyTrunk
+=
String
(
char
);
lastchar
.
type
=
"Number"
;
}
}
}
else
{
char
=
(
char
==
"."
)?((
displayTrunk
.
indexOf
(
"."
,
0
)
!=
-
1
)?
""
:
"."
):
char
;
calc
+=
String
(
char
);
displayTrunk
+=
String
(
char
);
historyTrunk
+=
String
(
char
);
lastchar
.
type
=
"Number"
;
}
}
}
// char is an operator
// char is an operator
else
{
else
{
...
...
src/board/UBFeaturesController.cpp
View file @
8c4f8182
...
@@ -99,12 +99,17 @@ UBFeaturesController::UBFeaturesController(QWidget *pParentWidget) :
...
@@ -99,12 +99,17 @@ UBFeaturesController::UBFeaturesController(QWidget *pParentWidget) :
mUserAnimationDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
userAnimationDirectory
());
mUserAnimationDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
userAnimationDirectory
());
mLibPicturesDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationImageLibraryDirectory
());
mLibPicturesDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationImageLibraryDirectory
());
mLibAudiosDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationAudiosLibraryDirectory
());
mLibVideosDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationVideosLibraryDirectory
());
mLibAnimationsDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationAnimationsLibraryDirectory
());
mLibInteractiveDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationInteractivesDirectory
());
mLibInteractiveDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationInteractivesDirectory
());
mLibApplicationsDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationApplicationsLibraryDirectory
());
mLibApplicationsDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationApplicationsLibraryDirectory
());
mLibShapesDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationShapeLibraryDirectory
());
mLibShapesDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
applicationShapeLibraryDirectory
());
mLibSearchDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
userSearchDirectory
());
mLibSearchDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
settings
()
->
userSearchDirectory
());
trashDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
userTrashDirPath
());
trashDirectoryPath
=
QUrl
::
fromLocalFile
(
UBSettings
::
userTrashDirPath
());
rootElement
=
UBFeature
(
QString
(),
QPixmap
(
":images/libpalette/home.png"
),
"root"
,
QUrl
());
rootElement
=
UBFeature
(
QString
(),
QPixmap
(
":images/libpalette/home.png"
),
"root"
,
QUrl
());
audiosElement
=
UBFeature
(
rootPath
,
QPixmap
(
":images/libpalette/AudiosCategory.svg"
),
"Audios"
,
mUserAudioDirectoryPath
,
FEATURE_CATEGORY
);
audiosElement
=
UBFeature
(
rootPath
,
QPixmap
(
":images/libpalette/AudiosCategory.svg"
),
"Audios"
,
mUserAudioDirectoryPath
,
FEATURE_CATEGORY
);
moviesElement
=
UBFeature
(
rootPath
,
QPixmap
(
":images/libpalette/MoviesCategory.svg"
),
"Movies"
,
mUserVideoDirectoryPath
,
FEATURE_CATEGORY
);
moviesElement
=
UBFeature
(
rootPath
,
QPixmap
(
":images/libpalette/MoviesCategory.svg"
),
"Movies"
,
mUserVideoDirectoryPath
,
FEATURE_CATEGORY
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment