Changeset 102:ba035eba07b4

Show
Ignore:
Timestamp:
11/22/08 15:59:36 (2 months ago)
Author:
Cyborg16@cyborg64-win.lan
branch:
default
Message:

Compilation fixes for windows and unittest code.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • dsss.conf

    r85 r102  
    1 # Copyright © 2007-2008 Diggory Hardy 
     1# Copyright © 2007-2008 Diggory Hardy 
    22# License: GNU General Public License version 2 or later (see COPYING) 
    33 
     
    77version (Posix) { 
    88    buildflags=-L-ldl 
    9     prebuild = mkdir bin -p 
    10 } else version (Windows) { 
    11     prebuild = mkdir bin 
    129} 
    1310 
  • mde/lookup/Options.d

    r101 r102  
    252252     * via hash-maps, which is a little slower than direct access but necessary since the option 
    253253     * must be changed in two separate places. */ 
    254     void set(T) (char[] symbol, T val) { 
     254    /+deprecated void set(T) (char[] symbol, T val) { 
    255255        static assert (TIsIn!(T,TYPES) && !TIsIn!(T, CTYPES), "Options.set does not support type "~T.stringof); 
    256256         
     
    264264            logger.error ("Options.set: invalid symbol"); 
    265265        } 
    266     } 
     266    }+/ 
    267267    /+ 
    268268    /** Get option symbol of an Options sub-class. 
    269269     * 
    270270     * Using this method to read an option is not necessary, but allows for generic use.  */ 
    271     T get(T) (char[] symbol) { 
     271    deprecated T get(T) (char[] symbol) { 
    272272        static assert (TIsIn!(T,TYPES), "Options does not support type "~T.stringof); 
    273273         
     
    283283     
    284284    /** List the names of all options of a specific type. */ 
    285     char[][] list () { 
     285    deprecated char[][] list () { 
    286286        char[][] ret; 
    287287        mixin (listMixin!(TYPES)); 
  • mde/mde.d

    r98 r102  
    1 /* LICENSE BLOCK 
     1/* LICENSE BLOCK 
    22Part of mde: a Modular D game-oriented Engine 
    3 Copyright © 2007-2008 Diggory Hardy 
     3Copyright © 2007-2008 Diggory Hardy 
    44 
    55This program is free software: you can redistribute it and/or modify it under the terms 
     
    4444        msg = "Welcome to mde.\nThis executable is only for testing, and\nas such doesn't do anything interesting."; 
    4545        debug msg ~= "\nRunning in debug mode."; 
    46         font = FontStyle.get("default");// get the default or fallback font 
     46        font = FontStyle.getDefault;   // get the default or fallback font 
    4747    } 
    4848    void sizeEvent (int,int) {};        // Don't care what the size is 
     
    8282    //END Main loop setup 
    8383     
     84    double pollInterval = miscOpts.pollInterval(); 
    8485    while (run) { 
    8586        mainSchedule.execute (Clock.now()); 
    8687         
    87         Thread.sleep (miscOpts.pollInterval); // sleep this many seconds 
     88        Thread.sleep (pollInterval);  // sleep this many seconds 
    8889    } 
    8990     
  • mde/setup/Init.d

    r101 r102  
    450450            foreach (name; stage_p.depends) 
    451451                stages[name].rdepends ~= key; 
    452         auto realMaxThreads = miscOpts.maxThreads
    453         miscOpts.set!(int)("maxThreads", 4);    // force up to 4 threads for unittest 
     452        int realMaxThreads = miscOpts.maxThreads()
     453        miscOpts.maxThreads = 4;   // force up to 4 threads for unittest 
    454454         
    455455        logger.level(Logger.Info);              // hide a lot of trace messages 
     
    491491         
    492492        stages = realInit;      // restore the real init stages 
    493         miscOpts.set!(int)("maxThreads", realMaxThreads)
     493        miscOpts.maxThreads = realMaxThreads
    494494        logger.info ("Unittest complete."); 
    495495    } 
  • mde/setup/paths.d

    r101 r102  
    281281    FilePath path = new FilePath (fontDir~file); 
    282282    if (path.exists && !path.isFolder) 
    283         return path.CString; 
     283        return path.cString; 
    284284    throw new NoFileException ("Unable to find font file: "~file); 
    285285    }