279 Commits

Author SHA1 Message Date
kruland2607
8a31d358d4 Set Spill hole in rocksimTestRocket3.rkt to 1.0 so the loader will
generate the warning.  I had changed generation of the SpillHole warning
to only be issued if the diameter is > 0.
2013-04-24 09:04:58 -05:00
soupwizard
448d2e606c Update travis-ci config file run unittests. Add new unittest ConfigurationTest.java. Fix FinRenderer.java to not have non-ascii character in a comment. 2013-04-23 14:26:46 -07:00
kruland2607
1f109acf41 Fix PluginTest by creating the PluginModule as a child of the
ApplicationModule.  Unfortunately, ApplicationModule requires a
preference provider to be set.
2013-04-22 15:32:29 -05:00
kruland2607
f899b9fb2e Fixed RocksimDocumentDTOTest by having RocksimTestBase extend
BaseApplicationAbstractTest to create a more complete Application
object.
2013-04-22 09:14:15 -05:00
kruland2607
2738f30489 Added BaseApplicationAbstractTest base class which will use Guice to
create the application framework.  It is roughly equivalent to the first
step of bootstrapping with ApplicationModule.  Modified unit tests which
require a more complete application framework.
2013-04-22 09:09:11 -05:00
kruland2607
2bad65410d Ignore changes to ignition, stage separation, and motor configuration. 2013-04-21 21:42:32 -05:00
Sampo Niskanen
dd5a16802b Merge branch 'master' into kruland-integration-ui
Conflicts:
	core/.classpath
2013-03-21 09:16:35 +02:00
Sampo Niskanen
170ce13c05 Data model refactoring 2013-03-01 08:41:47 +02:00
kruland2607
31d6baffd4 Back out directory watcher code since we aren't using it yet. 2013-02-13 10:21:14 -06:00
Sampo Niskanen
8c0c9bb10d Plugin system 2013-01-23 08:32:09 +02:00
kruland2607
593c639a06 Rework attachment loading. Construct a DocumentLoadingContext in
GenericLoader and pass into both OpenRocketLoader and RocksimLoader. 
the DocumentLoadingContext contains the OpenRocketDocument, MotorFinder,
and AttachmentFactory.
2013-01-10 21:11:57 -06:00
kruland2607
48adc0b7bf Rework the AttachmentFactory and Attachments. Make the Attachment
implementations stand on their own and be able to determine the location
of their bytes without needing a reference back to the
AttachmentFactory.  This required changing the loading semantics so the
OpenRocketDocument is created prior to beginning to read the xml file. 
Added an OpenRocketDocumentFactory to facilitate construction of
OpenRocketDocument objects.
2013-01-09 21:28:53 -06:00
kruland2607
acba62ce59 Rework Decal byte handling code and DecalRegistry. Added interface
DecalImage which is used by the Decal object to retrieve the bytes for
the image.  The DecalRegistry now operates as a factory and registry for
DecalImage objects.  The decal handling code in the saver is now greatly
simplified because the logical decal names are updated when constructed
by the DecalRegistry.
2013-01-06 16:58:18 -06:00
Sampo Niskanen
ef7c384f58 Merge branch 'master' into kruland-integration
Conflicts:
	core/build.xml
	core/src/net/sf/openrocket/file/openrocket/importt/OpenRocketLoader.java
	core/src/net/sf/openrocket/gui/figure3d/RocketFigure3d.java
	core/src/net/sf/openrocket/gui/main/BasicFrame.java
	core/src/net/sf/openrocket/gui/util/SaveFileWorker.java
	core/src/net/sf/openrocket/rocketcomponent/RocketComponent.java
	core/src/net/sf/openrocket/simulation/BasicEventSimulationEngine.java
2013-01-06 19:18:46 +02:00
Sampo Niskanen
011bcd27e2 Refactor convertStringToBytes method 2013-01-06 16:12:12 +02:00
Doug Pedrick
ffca820860 Initial file watcher code. 2012-12-19 20:22:14 -06:00
soupwizard
11c247135e fixed ~150 build warnings 2012-12-16 00:12:44 -08:00
soupwizard
dd0a9a12d9 removed unnecessary @SupressWarnings, to fix some build warnings 2012-12-11 18:15:42 -08:00
Sampo Niskanen
5412b8255b Merge branch 'integration' of github.com:kruland2607/openrocket
Conflicts:
	core/.classpath
	core/3d-Test-Junk/net/sf/openrocket/startup/Quick3dMain.java
	core/src/net/sf/openrocket/gui/figure3d/RocketRenderer.java
	core/src/net/sf/openrocket/gui/main/BasicFrame.java
2012-12-11 08:38:59 +02:00
Sampo Niskanen
ff22040df0 Refactor motor serialization/loading code 2012-12-10 22:44:06 +02:00
Kevin Ruland
e9060272e4 Created a GeneralRocketSaver object which is analogous to GeneralRocketLoader. Based on the StorageOptions, it determines how to save the file using a RocksimSaver or OpenRocketSaver as appropriate. Modified RocksimSaver and OpenRocketSaver so they only operate on OutputStreams. Removed methods from RocketSaver interface which operated on File. Fixed bug in DecalRegistry where it wouldn't handle absolute filenames. Fixed bug in BasicFrame where it would display ugly stuff for the filename. 2012-10-23 16:19:37 -05:00
Bill Kuker
4fe9dc4eef Fix to provide a FileInfo to the GeneralRocketLoader 2012-10-23 16:13:49 -05:00
Kevin Ruland
05d1b91d90 Sizable commit with lots of changes to support decals in openrocket files. Added support for zip container support. Changed Decal to hold a String instead of URL. Refactored GeneralRocketLoader out of the RocketLoader hierarchy so the GeneralRocketLoader knows about files and RocketLoader only knows about streams. Changed the OpenRocket file format to 1.6 and added <appearance> and it's children for ambient light and decals. Implemented a DecalRegistry which is a member of the OpenRocketDocument. This class is used to get InputStreams for decals by their names. 2012-10-23 15:54:45 -05:00
Sampo Niskanen
811292286e Make ClassBasedTranslator compatible with Guice 2012-10-15 07:33:24 +03:00
kruland2607
ecac762940 Break up the area/cg test cases and add some documentation describing
what they are doing.
2012-10-07 22:20:33 -05:00
kruland2607
4d77c817d8 Merged changes fixing NaN when computing fin CG. 2012-10-07 22:18:53 -05:00
kruland2607
9c3fce4517 Added couple of simple unit tests for computing area and cg for
Trapezoidal and Free Form FinSets.
2012-10-07 22:18:06 -05:00
Sampo Niskanen
506dc0c9b7 Unit rounding fine-tuning 2012-09-28 19:42:11 +00:00
Sampo Niskanen
9ed7836999 Remove invalid unit test 2012-09-16 12:39:45 +00:00
Sampo Niskanen
308203c9c9 Remove dependency on java.text.Normalize 2012-08-27 19:46:44 +00:00
Sampo Niskanen
31ace7b312 Material localization support 2012-08-25 20:10:58 +00:00
Kevin Ruland
ab4c14d3a0 Fix correctness and threading issue in new Manufacturer lookup mechanism. It was incorrect because the Manufacturer objects should be registered under the searchNames. The threading correctness is only an issue in the Manufacturer.get(String) method when the name does not exist. This is handled by using external locking mechanism. Added a unit test which exposed the problem looking for the manufacturer "Contrail_Rockets". 2012-08-24 20:31:13 +00:00
Kevin Ruland
ba1c0fd2fa Removed FIXME comment since I'm convinced the test case is correct. Recall these tests were originally in a main loop. 2012-08-23 02:37:51 +00:00
Sampo Niskanen
ceeade06b4 Negative number test 2012-08-13 20:47:29 +00:00
Kevin Ruland
43b269c0f4 Change the implementation of ArrayUtils.range to include the stop value if it is a multiple of step. 2012-08-10 20:03:21 +00:00
Kevin Ruland
301067e301 Added unit tests and fixed rounding problem in ArrayUtils.range(). 2012-08-10 19:09:27 +00:00
Kevin Ruland
a5c3c1ac76 Rework the CustomExpression evaluation to use SimulationListeners. Removed the OpenRocketDocument member variable from the Simulation object. 2012-08-08 02:24:40 +00:00
Richard Graham
3d5ae6752a Big update to custom expression feature.
- supports range and index subexpressions and many new operators
 - switched to my patched version of exp4j to support all this.
 - expressions belong to rocket document. Accessed from analysis menu.
 - expression importing from file
 - datatypes section defined in file for storing datatypes other than internal ones
 - flightdatatype fix to forget outdated types
 - many GUI fixes to custom expressions
 - new unitgroups supported. Auto unit detection for SI units in custom expressions.

Had to carefully merge loading/saving code with Kevins recent de-localization update. Hopefully changes to materials saving kept but switched datatype access to just using symbol as the key.

Hopefully can get the changes to exp4j upstream so we don't need to keep using this patched version.
2012-08-05 23:59:54 +00:00
Kevin Ruland
77e3652249 De-localize Material and FlightDataType objects when persisting in ork files. Added a String key to each of these objects which holds on to a unique identifier which is stored in the ork file. User defined Materials are given a key which is defined as "UserDefined." + name.
The construction pattern for Material has changed so explicitly passing in the userDefined boolean is no longer required.  Instead there are two different factory methods to be used.  Direct construction of Material derived classes is no longer allowed.

The persistence mechanism for Materials in perferences has changed.  It will now persist the key and name but still supports reading old format.

The example files have been regenerated, but will need to be regenerated again prior to an official build in order to get the version string correct.
2012-07-31 21:20:55 +00:00
Kevin Ruland
c6a9f17179 Merge branches/froyo_12.03 to head. 2012-07-18 14:42:27 +00:00
Kevin Ruland
357f370096 Extract Transformation.main to junit test. 2012-07-12 02:44:32 +00:00
Kevin Ruland
310e35293a Extract Quaternion.main to junit test. 2012-07-10 18:52:13 +00:00
Kevin Ruland
f08ad83e5f Extract PolyInterpolator.main into Junit test case. 2012-07-10 18:42:35 +00:00
Kevin Ruland
44b1593955 Pull LinearInterpolator.main() into a JUnit test. 2012-07-10 17:53:34 +00:00
Kevin Ruland
f191e47f5b Extract Base64.main() as a unit test. 2012-07-10 17:08:39 +00:00
Sampo Niskanen
723539619c Component preset updates 2012-06-18 19:48:57 +00:00
Richard Graham
71b36bc481 - Implemented copying of custom expressions to other simulations in expression builder dialog. Note the small changes to various files are to allow simulations access to parent document.
- Switched to unicode char escapes
- Removed dynamic setting of flightdatatype priority
- Now hiding up down arrows in custom expression pane when unusable
- Localized custom expression operator discriptions.
2012-06-11 04:47:49 +00:00
Doug Pedrick
eb0cfe141e Added ruler graphic to printed output; improvements to layout and margins in printing; bug fix in PrintUnit; other
minor printing related cleanup.
2012-05-28 04:28:26 +00:00
Kevin Ruland
4abceb9185 Minor modification to test case which makes setting breakpoints easier. No functional or assert changes. 2012-05-23 14:38:36 +00:00
Kevin Ruland
0302130c11 My assessment of why IntegrationTest was failing was incorrect. After perusing the history I found that in repository revision 599, I introduced changes to the computation of Transition volume which accounted for the volume of the shoulders as well as the body of the transition. This change broke the computation of CG. This commit reverts IntegrationTest and adds some cg tests to SymmetricComponentVolumeTest which contains the values produced by the old code. A future commit will correct SymmetricComponent.getCG and all these tests will work again. 2012-05-23 14:23:01 +00:00