Posts

flutter - How to stretch an icon to fill parent? -

i need icon dynamically stretch fill parent container. i don't think possible directly on icon (since has size property), there solution i'm overlooking? i believe can use fitted box expanded https://docs.flutter.io/flutter/widgets/expanded-class.html https://groups.google.com/forum/#!msg/flutter-dev/lsgdu1yl7xc/0pys2qrzbqaj https://docs.flutter.io/flutter/widgets/fittedbox-class.html https://docs.flutter.io/flutter/painting/boxfit-class.html new expanded( child: new fittedbox( fit: boxfit.fill, child: new icon(icons.home), ), ), please note in docs expanded has wrapped in colium, row or flex widget.

No validator could be found for type: java.lang.Long :No validator could be found for type: java.lang.Long -

i have object class has no required field except id. here code: entity @xmlrootelement @table(name = "t_host_spec") @cacheable(false) @namedqueries({ @namedquery(name = hostspec.find_all, query = "select m hostspec m") ,@namedquery(name = hostspec.find_by_ip_context_path_port, query = "select m hostspec m m.ip = :ip , m.contextpath =:contextpath , m.port =:port ")}) public class hostspec extends abstractentity { @id @sequencegenerator(name = "host_spec_sequence_generator", sequencename = "host_spec_seq", initialvalue = 1, allocationsize = 1) @generatedvalue(strategy = generationtype.sequence, generator = "host_spec_sequence_generator") @xmlelement(name = "id") @notnull @column(name = "id", nullable = false) private long id; @size(max =200 ) @column(name = "app_name",length = 25) @xmlelement(name = "app_name") private string ap...

angular - ngif how to give multiple conditions -

this html file <div class="conform"> <button (click)="clicked(i)" class="btn btn-primary">join ride</button> <div class="dialogboxstyle" *ngif="showindex===i"> <p>your pickup time:</p> <p>8:30am </p> <p> <button (click)="cancel()">cancel</button> <button>confirm</button> </p> </div> </div> this component .ts file public showdialog:boolean = false; public showindex:number; clicked(i:any) { this.showdialog = true; this.showindex = i; } by default when page loaded popup in open stage need hidden stage unless until click it. tried using ngif="showindex === && showdialog" but not working.

c# - How to do view 2nd page in paging -

i able view 1st page upon search if data more 10 rows showing me full grid bind. how can view 2nd page public void fncfillapplication() { try { dataset ds = new dataset(); ds.readxml(server.mappath("application.xml")); if (ds.tables[0].rows.count != 0) { gvapplication.datasource = ds; gvapplication.databind(); } } catch (exception ex) { ex.message.tostring(); } on page index applying paging , datasource xml protected void onpageindexchanging(object sender, gridviewpageeventargs e) { gvapplication.pageindex = e.newpageindex; this.fncfillapplication(); } i able view 1 st page when doing paging clicking 1 when click on 2nd page full grid bind. how able see data further if pagesize="10" data in grid 20 rows.how see last 10 rows. set properties- enablepaging ...

swift3 - How to count number of uicollectionview's rows in swift -

Image
i need determine uicollectionview's height. let layout = contactcollectionview.collectionviewlayout let heightsize = string(int(layout.collectionviewcontentsize.height)) the above solution works on situations in project. in specific situation need count number of rows , multiple number find height. func collectionview(_ collectionview: uicollectionview, numberofitemsinsection section: int) -> int { // height = (count rows) * 30 . every cell height 30 // every cell has different width. return (presenter?.selectedcontact.count)! } how can find number of rows? update look @ image. this collectionview. every cell has different width(because string). has different rows. width of collectionview width of view.frame you can compare if collectionview 's width greater total previous width(s) increment rowcounts one. assuming implementing uicollectionviewdelegateflowlayout methods , per each cell know dynamic width @ moment. if...

javascript - Any way to generate documentation of a website project in a restricted environment? -

following title, have unable execute cmdlets, exe, shellscripts, vb. able open git bash, again, have no admin rights. there ways of accomplishing this? 1 idea had create local website in form upload zip file website stuff repacks , sends via local zip file download? edit: trying document out front end site coded in react. thing able run within git bash. no execution of .exe's or cmdlets withing git bash works though... well, apparently if u have git bash in ur restricted laptop , have ability push ur commit git hub, seems using edoc node module job. instead of saving globally (which won't work) npm install -save esdoc. instead of running esdoc -c [json file], use ./node_modules/esdoc/out/src/esdoccli.js -c [json file] worked beautifully me. hope helps faces similar situation me. feel free add additional methods generate documentation.

c++ - Copy constructor for C volatile bitfield struct -

good day i trying use c sd driver/file system libary (keil mdk), in c++11 project. added pack manager in keil mdk 5.23. compiling armcc 5.06u4 i warning class "_arm_mci_status" has no suitable copy constructor" odd, because header declared in has extern "c" { . by default, pack has no option set c or c++, have manually added file c file. still problem. the struct declared, within extern "c" { as: typedef volatile struct _arm_mci_status { uint32_t command_active : 1; ///< command active flag uint32_t command_timeout : 1; ///< command timeout flag (cleared on start of next command) uint32_t command_error : 1; ///< command error flag (cleared on start of next command) uint32_t transfer_active : 1; ///< transfer active flag uint32_t transfer_timeout : 1; ///< transfer timeout flag (cleared on start of next command) uint32_t transfer_error : 1; ///<...