Skip to content
Snippets Groups Projects
Select Git revision
  • f022bb7ad409220c2d0e55d1afa4b85047279333
  • master default protected
  • overlaps_tags_and_distributed_export
  • patches-4.14
  • steplayer
  • bl
  • pluginMeshQuality
  • fixBugsAmaury
  • hierarchical-basis
  • alphashapes
  • relaying
  • new_export_boris
  • oras_vs_osm
  • reassign_partitions
  • distributed_fwi
  • rename-classes
  • fix/fortran-api-example-t4
  • robust_partitions
  • reducing_files
  • fix_overlaps
  • 3115-issue-fix
  • gmsh_4_14_0
  • gmsh_4_13_1
  • gmsh_4_13_0
  • gmsh_4_12_2
  • gmsh_4_12_1
  • gmsh_4_12_0
  • gmsh_4_11_1
  • gmsh_4_11_0
  • gmsh_4_10_5
  • gmsh_4_10_4
  • gmsh_4_10_3
  • gmsh_4_10_2
  • gmsh_4_10_1
  • gmsh_4_10_0
  • gmsh_4_9_5
  • gmsh_4_9_4
  • gmsh_4_9_3
  • gmsh_4_9_2
  • gmsh_4_9_1
  • gmsh_4_9_0
41 results

SphericalRaise.h

Blame
  • Model.java 1.18 KiB
    package org.geuz.onelab;
    
    import java.io.File;
    import android.net.Uri;
    import java.util.Comparator;
    
    import android.graphics.Bitmap;
    import android.graphics.BitmapFactory;
    
    class Model {
        private String _name, _summary;
        private File _file;
        private Bitmap _bitmap;
        private Uri _url;
        public Model(String name, String summary, File file)
        {
            _name = name;
            _summary = summary;
            _file = file;
        }
        public String getName() { return _name; }
        public String getSummary() { return _summary; }
        public File getFile() { return _file; }
        public Bitmap getBitmap() { return _bitmap; }
        public Uri getUrl() { return _url; }
        public void setBitmap(File f)
        {
            BitmapFactory.Options options = new BitmapFactory.Options();
            options.inJustDecodeBounds = false;
            options.inPreferredConfig = Bitmap.Config.RGB_565;
            options.inDither = true;
            _bitmap = BitmapFactory.decodeFile(f.toString(), options);
        }
        public void setUrl(Uri url) { _url = url; }
    }
    
    class ModelComp implements Comparator<Model>{
        @Override
        public int compare(Model e1, Model e2) {
            return e1.getName().compareTo(e2.getName());
        }
    }