Posts

Showing posts from July, 2012

Python 3.4 tkinter button -

my program should destroy btn1 , create again after 1 second in loop. don't no why program destroy btn1 , don't show again. have idea why? from tkinter import * import random def hide(): btn1.destroy() btn1.after(2000,hide) def show(): btn1 = button(root, bd=c, text="hello\nworld", relief="ridge", cursor="trek") btn1.grid(row=0,column=0) btn1.after(3000,show) root = tk() root.geometry("350x150+400+400") c=random.randint(20,40) btn1 = button(root, bd=c, text="hello\nworld", relief="ridge", cursor="trek") btn1.grid(row=0,column=0) btn1.after(2000,hide) btn1.after(3000,show) root.mainloop() it work if use grid_forget instead of creating new object each time. note happens @ multiples of 6 seconds (2000 x 3000) depends on 1 last 1 execute. def hide(): btn1.grid_forget() btn1.after(2000,hide) def show(): btn1.grid(row=0,column=0) btn1.after(3000,show...

Android studio gradle deleted -

Image
i accidentally deleted gradle files android studio installed. following this tutorial resolve issue deleted gradle files cant create new project in android studio. , cant build run or anything. when start android studio shows me error in following image: if open plugin manager shows android support, cloud disabled in image: in settings build tools not show gradle: and in module settings shows this: please guide me in this. cant reinstall android studio, sdk , again have done many settings(installed plugins , git configs etc) in studio, reinstalling not option. help? one non-technical solution install instance of android studio @ different location on system. can compare directories of where deleted files , copy on files not there in original installation.

angularjs - Why does not work inserting HTML in Angular JS? -

i have html code: <div dynamic="html"></div> and angular js in ajax response: $scope.html = content; my dirrective dynamic looks as: .directive('dynamic', function ($compile) { return { restrict: 'a', replace: true, link: function (scope, ele, attrs) { scope.$watch(attrs.dynamic, function(html) { ele.html(html); $compile(ele.contents())(scope); }); } }; }) so, when have $scope.html html code in response dynamic not insert(prepend) code in div block. why? ...and angular js in ajax response: i cannot see ajax call being made template. so, when have $scope.html html code in response dynamic not insert(prepend) code in div block. why? you not seeing content because html , callback response in $watch undefined from understandin...

csv - How to match every beginning of new line of text in Regex? -

i'm in process of creating csv file out of text file. new regex , need finish csv file. what need remove every new line of text , put them in 1 single line. for example, data: abc company inc 123 street winchester, ky needed in format: abc company inc;123 street;winchester, ky plus , on file... has several entries 1 line-break every after 1 company. it's this: abc company 123 street winchester, ky def company 456 street winchester, ky and make so: abc company;123 street;winchester, ky def company;456 street;winchester, ky can in regex? if so, how? more info: this not programming or coding related issue. it's more of data conversion or manipulation. i'm using text editor. need edit text file (mined data) , convert csv file. if there other tools might use this, please mention it. update: with particular problem @ hand, current level of knowledge, found answer of bohemian more helpful in case. did me task. however, answer provided...

codeigniter 3 URL Remap -

i trying remap old urls http://www.example.com/ipranges.php?reqinfo=180.94.79.0-180.94.79.255 in codeigniter 3 not working. here route this. can help? thanks $route['ipranges.php?reqinfo=/(:any)'] = "ipinfo/ipranges/$1"; -codeigniter using uri segments , , there "ipranges.php..." in routes not allowed , can't used in codeigniter. -in codeigniter url-> there 1st segment indicates controller ,second segment point method , third , on, parameters method. -so here url=> www.example.com/controller/method/parameter...... -if using routing,than can remap them -----www.example.com/slug --here in routes.php $route['slug'] = "controller/method/$1";

asp.net mvc - ASP .Net MVC and WCF Identity (Claims) Integration -

we're building platform client asp .net mvc one, using asp net identity 2.0 authentication , authorization (using claims), works great on web side. we have wcf service allows crud operations on database (for multiple client applications), gets requests asp .net mvc client. want validate (authenticate & authorize) user before making specific crud actions in wcf side, need claims of user client, , perform validations (preferably in clean manner using headers or binding wcf able support matter). i've been searching different forums no simple answer\tutorial specific scenario. can assist on matter? thanks, nir. i love this: in iendpointbehavior implementation on client end: public object beforesendrequest(ref message request, iclientchannel channel) { request.headers.add(messageheader.createheader("token", "http://myurl.com/service/token", _thetoken)); return null; } then on service end add serviceauthenticati...

node.js - node-uuid IS installed but require('node-uuid') fails -

Image
i'm getting error in pm2 logs indicates line in player.js mongoose model tries load node-uuid failing. don't understand why because installed , node_modules folder , below owned user running node app. i'm baffled error...

postgresql - SQL NULL in DDL (Data Definition Language) -

i imported datas .txt file database via postgresql. problem is, columns of movies empty. e.g there no rating film "abcd" , when importing via copy postgresql throws error "no data in column". how can catch error in create table order. tried "null", not work either. create table movies ( imdib varchar not null, name varchar not null, year integer null, rating float null , votes integer null , runtime varchar null , directors varchar null , actors varchar null , genres varchar null ); copy movies 'c:\users\max\desktop\imdb_top100t.txt' delimiter e'\t' ; error message: error: missing data column „year“ context: copy movies, line 3060: „tt0283003 “ ********** error ********** error: missing data column „year“ sql status:22p04 context: copy movies, line 3060: „tt0283003 “ edit: on line 3060 tt0081590 sällskapsresan eller finns det svenskt kaffe pÃ¥ grisfesten 1980 7.3 4477 107 mins. las...

ml - Missing Option.default in OCaml 4.01.0 -

i'd use string.set.choose some_set pick string set. this method returns stringoption, want use method return value of second, hence i'd cast stringoption string. i know according ocaml docs ( link here ) option.default supposed reason it's missing (although option rest of methods exists). is there way workaround or let next method accept stringoption? thanks, first, not ocaml docs :-) it's add-on library. particular repository obsolete (like else on sourceforge), , option module has been incorporated ocaml batteries included batoption module. batteries add-on library, 1 of used ones. you can write own function extract string string option, long decide want when value none . in case, there's no string of course. one possibility raise exception in case. if you're positive there's string, exception never happen. if happen, know have problem. so, write function this: let string_of_string_option = match | none -> f...

javascript - Trying to add a link to open a 'steam://run/' link to a random word array -

so i'm messing creating random word picker pick steam game library, want add 'launch' link each random word. heres code; <html> <head> <link rel="stylesheet" type="text/css" href="steam_gen_style.css"> <title>untitled</title> <script language="javascript"> <!-- // use following variable specify // number of random words var numberofwords = 28 var words = new buildarray(numberofwords) // use following variables // define random words: words[1] = "ark: survival evolved/346110" words[2] = "portal 2/620" words[3] = "left 4 dead 2/550" words[4] = "cs:go/730" words[5] = "and yet moves/18700" words[6] = "bridge constructer/250460" words[7] = "bridge constructer medieval/319850" words[8] = "half-life 2/220" words[9] = "gta v/271590" words[10] = "antichamber/219890" words[11] = "...

java - How to remove the arifacts -

Image
i applying operations on image , result image should resemble image posted in first figure below, resultant image see in figure 2 contains unwanted structure or artifacts. how can eliminate these artifacts? figure 1: figure 2:

active directory - Is is possible to use Azure AD as a SAML compliant Identity Provider? -

and if possible how 1 set (minimal installation). have seen there acs doesn't support saml protocol. know can use ad fs bridge want simple possible - out of box. thanks in advance. yes can done. key "missing" documentation: set-msoldomainauthentication ,,, -preferredauthenticationprotocol samlp refer: saml : federating azure active directory using saml .

asp.net - Which encryption algorithm does Entity Framework use to save passwords? -

i used entity framework code first create simple crud web application in asp.net mvc 5. mvc 5 came ready use registration , authentification. want know what's encryption algorithm used save pass words? entity framework save passwords. saved password hashed (you don't encrypt passwords, hash them) in layer before pass off entity framework (if pass password down far @ all). asp.net mvc 5 "layer before" , how handles passwords depends on which options chose security .

Swift object to reference itself (without optionals) -

i trying create object class contain reference self or object: class myobject { let owner: myobject init(owner: myobject) { self.owner = owner; } } class rootobject : myobject { init() { self.owner = self } } var root = rootobject() var child = myobject(root) // child.owner == root // child.owner.owner == root is possible modify code , implement idea without use of optionals?

php - Display product under its category -

i working in wordpress.i have display different subcategory.now click on each category display product under it. my code this: <?php $query3 = "select t.* wp_terms t join wp_term_taxonomy tt on tt.term_id = t.term_id tt.parent = ".$res2->term_id; $result3 = $wpdb->get_results($query3); foreach($result3 $res3) { ?> <li> <a href="##" class="sub_cat_name" data-id = "<?php echo $res3->term_id; ?>"><strong><?php echo $res3->name; ?></strong></a> <ul class="tmp"> <li class="tmp_li"> </li> </ul> </li> <?php } ?> and jquery code is: <script> $(document).ready(function(){ $(".sub_cat_name").click(function(){ var cat_id = $(this).data("id");...

android - Cordova 5 building using both grade/ant throwing java compile errors -

installed tools listed in android sdk manager. java_home points jdk7 gradle_home, ant_home, android_home other configured environment variables. already tried removing & adding again platform android cordova project. c:\users\pratik\documents\routeplannerfront\platforms\android\cordovalib\src\org \apache\cordova\cordovaclientcertrequest.java:25: error: cannot find symbol import android.webkit.clientcertrequest; ^ symbol: class clientcertrequest location: package android.webkit c:\users\pratik\documents\routeplannerfront\platforms\android\cordovalib\src\org \apache\cordova\cordovaclientcertrequest.java:32: error: cannot find symbol private final clientcertrequest request; ^ symbol: class clientcertrequest location: class cordovaclientcertrequest c:\users\pratik\documents\routeplannerfront\platforms\android\cordovalib\src\org \apache\cordova\cordovaclientcertrequest.java:34: error: cannot find symbol public cordo...

ios - Automatically Generated Primary Key -

i developing ios app.using core data storing data.but primary keys automatically generated.data can stored id. //code nsmanagedobjectcontext *context = [self managedobjectcontext]; nsmanagedobject *userobj = [nsentitydescription insertnewobjectforentityforname:@"detailsave" inmanagedobjectcontext:context]; [userobj setvalue:[nsnumber numberwithinteger:_userobj.userid] forkey:@"id"]; [userobj setvalue:_titlelabel.text forkey:@"title"]; nsinteger valint = 1; nsnumber *val = [nsnumber numberwithinteger:valint]; [userobj setvalue:val forkey:@"quantity"]; nsstring *maxpurch = [dict objectforkey:@"_max_purchases_per_user"]; nsnumber *maxval = [nsnumber numberwithinteger:[maxpurch integervalue]]; [userobj setvalue:maxval forkey:@"max_purch"]; nsstring *maxpurch = [dict objectforkey:@"_max_purchases"]; nsnumber *max = [nsnumber numberwithinteger:[maxpurch integervalue]]; ...

android - How to store string / integer value in Broadcast receiver.? -

i have 1 receiver extend broadcast receiver.i passing string value main activity. when activity create pass value receiver.i can receive string value. problem is, can not save string values. i have tried shared preference context in broadcast receiver not working. my receiver code here. public void onreceive(context context, intent intent) { if(intent.getaction().equals("my.action.string")){ state = intent.getextras().getstring("value"); toast.maketext(context, "this state : " + state, toast.length_short).show(); sharedpreferences prefs = context.getsharedpreferences("myprefs", context.mode_private); editor editor = prefs.edit(); editor.putstring("state_lock", state); editor.commit(); p = prefs.getstring("state_type", state); toast.maketext(context, "the state type : "+ p, toast.length_short).show(); } with...

javascript - No compatible binary build found for this package -

when run both meteor add both meteoric:ionic-sass , meteoric:ionicons.-sass , shows error below. => errors while adding packages: while checking stevezhu:sass@1.3.7: error: no compatible binary build found package. contact package author , ask them publish platform. i use windows machine way..is problem? have posted on github page think not maintained or something. i having issue different package while trying work on windows machine. ended calling meteor update while in directory meteor project working on , fixed it.

function - select a row of matrix based on Date in R -

i'm new in r.i have small question. want select 1 row based on date. write function doesn't work.here example. here data sample: example date b 1 01/01/2000 0.6765442 1 2 01/01/2001 0.1374231 10 3 01/01/2002 0.6917205 0 4 01/01/2003 0.1440152 5 5 01/01/2004 0.1143759 8 6 01/01/2005 0.3379550 7 7 01/01/2006 0.4477631 9 8 01/01/2007 0.6164849 6 9 01/01/2008 0.1232872 8 10 01/01/2009 0.3511471 6 i tried using code: test=function(data,text) { ( in (1:col(data))) { if (data[i,1]=="text") { l=i r1=data[l,] return(r1) } } } you should use r-vectorized feature subset data. no need use for-loop here. example: data[data$date == "01/01/2001",] ## date b ## 2 01/01/2001 0.1374231 10 of course can wrap in function: subset_by_date <- function(date_txt,data) data[d...

xml - Android Studio - Cannot Resolve Symbol 'R' -

this question has been asked many times before, have tried , nothing has worked. cleaning, rebuilding, syncing gradle, editing xml. i error "cannot resolve symbol 'r'" on every file has 'r.blah.blah' in it. this line of code error shows up. int gray = getresources().getcolor(r.color.card_gray); does have idea why happening? i've tried restarting hasn't worked, i'm thinking it's bug in current android studio version. edit: android manifest , beginning of java file (one of affected ones) i have 3 manifests, 1 each module (cardsui, silk, app), i'm making icon pack. error happening in 3 modules. app: too long post, here gist: app manifest cardsui: <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.afollestad.cardsui" android:versioncode="1" android:versionname="1.0"...

distributed computing - Hazelcast 3.3 - EntryProcessor is accessing "non-local" keys -

i'm using hazelcast 3.3. one member writes entries imap , calls map.executeonentries(myentryprocessor) . task of entryprocessor print entries on console. however, members (3 other , 1st 1 = 4 members) seem print overlapping set of entries. understanding entryprocessors entries corresponding localkeyset() . however, appears thats not case. could please explain behavior? your reasoning correct. entryprocessor should touch local keys. what using key? hazelcast uses serialized version of key actual key; perhaps have 2 different key instances lead same 'tostring', binary content different. i have shot myself in foot e.g. hashmap being part of key; can lead different binary content though actual content same, , strange behavior. if using e.g. long or string key; can't explain behavior seeing. how difficult reproduced?

How can i change working of forall in agda? -

i working pair of stream of rationals, lets (l,r) l , r stream of rationals. there 3 conditions l , r both have satisfy valid. have written code as.. iscut_ : cut → set iscut x = (p q : pair ) → if((((p mem (getlc x)) ∨ (p mem (getrc x)))) ∧ ((not (p mem getlc x)) ∨ (not (p mem getrc x))) ∧ (not (p <pair q) ∨ ((p mem getlc x) ∨ (q mem getrc x))))then ⊤ else ⊥ i wanted change return type of function bool. here cut means (l, r) , mem membership. the problem coming forall p q expect return type set . how should handle desired result. you can write this: iscut : cut → (p q : pair) → bool iscut x p q = (((p mem (getlc x)) ∨ (p mem (getrc x)))) ∧ ((not (p mem getlc x)) ∨ (not (p mem getrc x))) ∧ (not (p <pair q) ∨ ((p mem getlc x) ∨ (q mem getrc x))))

php - json_encode doens't work in my Symfony2's controller -

i'm new in symfony2 , angularjs. i´m trying use json_encode show database's content. doens't work. controller: public function catalogonewaction() { $data = $this->getdoctrine()->getmanager() ->getrepository('acmeretrobundle:game')->findall(); return $this->render('acmeretrobundle:default:catalogonew.html.twig', array('data' => json_encode($data)));} this html.twig: {% verbatim %} <div ng-app="myapp1" ng-init="mydata = {{ list|raw }}"> <table id="sorteddata"> <tr><th>t1</th><th>t2</th></tr> <tr ng-repeat="data in mydata | filter:sortdata"> <td>{{data.nombrejuego}}</td> <td>{{data.description}}</td> </tr> </table> </div> {% endverbatim %} and app.js: angular.module('myapp1', []). filter('sortdata', function() { alert('hi'); return out; ...

sql server - Make a query which adds a column to display the number of repetitions of every items in a table -

i need sql server command, should add column in table consisting of number of times each element in specific column repeated. , want table display no repetition of item beeing counted . table. medication_id prescription_id dossage 12 1013 blablabla 17 1013 blablabla 15 1013 blablabla 12 1013 blablabla 12 1013 blablabla 12 1013 blablabla 12 1014 blablabla 12 1014 blablabla 12 1014 blablabla 15 1013 blablabla 15 1013 blablabla 17 1015 blablabla 12 1016 blablabla i want generate this: medicatition id | n...

c++ - Copy every other element using standard algorithms (downsampling) -

say have std::vector n elements. copy every n-th element of new vector, or average element copy (downsample original vector). want this std::vector<double> vec(n); long n = 4; std::vector<double> ds(n/n); for(long = 0; < ds.size(); i+=n) { ds[i] = vec[i*n]; } or for(long = 0; < ds.size(); i+=n) { double tmp = 0; for(long j = 0; j < n; j++) { tmp += vec[i*n+j]; } ds[i] = tmp/static_cast<double>(n); } is there way using standard algorithms of c++? using std::copy binary functions? have billions of elements want treat way, , want fast possible. ps: prefer not use external libraries such boost. for readability, loop idea, pointed out vlad in comments. if want someting this, try: int cnt=0,n=3; vector<int> u(v.size()/3); copy_if (v.begin(), v.end(), u.begin(), [&cnt,&n] (int i)->bool {return ++cnt %n ==0; } ); if want average, it's getting worse you'd have simi...

mysql - Joining product attributes table with the product table to display product -

Image
i have 3 tables listing products product attributes product table dummy data product_attributes dummy data attributes dummy data kespersky antivirus (productid = 1) has no attributes iphone (productid =2) has 2 attributes applicable it, memory , resolution both in attribute table has value stored in product_attribute table. how join these tables show/display both products there corresponding attributes? edit i need display these products the following work number of attributes: select product.productid, product.name, group_concat(concat(attr.attributename, ":", pa.attributevalue)) product left outer join product_attributes pa on (pa.productid = product.productid) left outer join attributes attr on (attr.attributeid = pa.attributeid) group product.productid, product.name

converting matlab code to c code readiness error -

Image
i want convert matlab code c code.but when trying do lots of warnings comping in code readiness report. although have sorted out lot of issues still there functions not supported , need alternative. kindly tell me alternative codes errors. let me more specific: these lines of function causing issue-: fn = fieldnames(pars); %current parametres fieldnames main_fn = {'algorithm'}; pm_fn = {'pm_tau','pm_window','pm_keypoints','pm_harris_prctile','pm_searchrange'}; m_fn = {'window','range','tau','epsilon','growing','init_seeds_accept', 'seeds_accept','searchrange','searchrangev', 'max_candidates','vis_step','mu','csbeta','csalgorithm','grow_version'}; now in saying code generation supports cell operations varargin , vararout if wants see full function here is: http://paste.ofc...

javascript - React self-modifying component with proper state/props -

i'm working on pet project right , decided use react view. i'm far developing i'm starting realize might not understand how use react because seems in order simple things have go extreme measures! so, time arbitrary example! here's code working on jsfiddle var name = react.createclass({ render: function() { return <button onclick={this.props.onclick.bind(null, this.props.id, 'john')}>{this.props.value}</button> } }); var namecontainer = react.createclass({ getinitialstate: function() { return { names: [ { id: 1, name: 'fred' }, { id: 2, name: 'george' } ] }; }, handleclick: function(id, newname) { names = this.state.names; names.map(function(obj){ if (obj.id === id) { obj.name = newname; } return obj; }); this.setstate({ names: names...

matrix - JavaFX 8 Transform to pitch, yaw and roll rotation angles -

Image
implementing answer this thread have code translates deltayaw, deltaroll , deltapitch angles 1 angle , rotates node around it. angles taken parameters momentary changes of angles since giving whole angles ignore changes in orientation. public static void matrixrotate(group n, double deltaroll, double deltapitch, double deltayaw){ double a11 = math.cos(deltaroll)*math.cos(deltayaw); double a12 = math.cos(deltapitch)*math.sin(deltaroll)+math.cos(deltaroll)*math.sin(deltapitch)*math.sin(deltayaw); double a13 = math.sin(deltaroll)*math.sin(deltapitch)-math.cos(deltaroll)*math.cos(deltapitch)*math.sin(deltayaw); double a21 =-math.cos(deltayaw)*math.sin(deltaroll); double a22 = math.cos(deltaroll)*math.cos(deltapitch)-math.sin(deltaroll)*math.sin(deltapitch)*math.sin(deltayaw); double a23 = math.cos(deltaroll)*math.sin(deltapitch)+math.cos(deltapitch)*math.sin(deltaroll)*math.sin(deltayaw); double a31 = math.sin(deltayaw); double a32 =-math.cos(...

condition to check if the session variables as well as get and post have been destroyed in php -

the code like:(it last page of web-app have made) <?php if(isset($_get['var']) { session_start(); $a=$_session['prev_defined']; #more use of session variable session_destroy(); $_session = array(); unset($_get); unset($_post); } ?> now when execute web application runs fine , when refresh last page code given above warning message shows of undefined symbol because $_session variables $_get , $_post have been deleted. want display message "session over" on refresh. how it? put if condition? have tried put above code in if($_session) { #entire code above } else { echo"session over"; } but displayes message undefined variable _session <?php if(isset($_get['var']) { if(isset($_session)) { session_start(); $a=$_session['prev_defined']; #more use of session variable session_destroy(); $_session = array(); unset($_get); unset($_post); } else { echo"session over...

.htaccess - RedirectPermanent on localhost without contacting other domains -

lets says have .htaccess file following apache redirect webbrowsers specifik iconfile. redirectpermanent /favicon.ico http://example.com/folder/icon.ico so guess when test website on localhost every time browser looking http://localhost/favicon.ico gets send http://example.com/folder/icon.ico how avoid this? on localhost redirect http://localhost/folder/icon.ico like: redirectpermanent /favicon.ico http://localhost/folder/icon.ico what correct/optimal way solve problem. your problem mod-alias not flexible use variables should use mod-rewrite . not sure why want anyway, can try this. rewriteengine on rewriterule ^favicon.ico$ http://%{http_host}/folder/icon.ico [r=301,l]

image processing - How do I close off edges after Canny edge detection for filling region in Matlab using imfreehand? -

Image
i need close boundaries of person have got using canny edge detector. aim able extract filled (white) silhouette of person , save image. i read imfreehand might used freehand drawing, how implement purpose? (there might multiple gaps in boundaries in datasets using imfreehand multiple times might required) you try using morphological operators such imfill or bwmorph (with bridge) bw2 = bwmorph(bw,'bridge');

javascript - Error when trying to query with $near in find() -

i'm trying use $near operator $find(), can't managed done. have tried 2 methods userschema var userschema = new db.schema({ email: { type: string, unique: true, lowercase: true }, password: { type: string, select: false }, company_name: string, location_verified: { type:boolean, default:false}, account_verified: { type:boolean, default:false}, date_joined: {type:date, default:date.now}, business_details: { business_phone: string, business_email: string, business_location:[] } }) //index 2d userschema.index({ 'business_detail.business_location': '2d' }); var user = db.model('user', userschema); method 1 var limit = req.query.limit || 10; var maxdistance = req.query.distance || 8; maxdistance /= 6371; var coords = []; coords[0] = 101.6833; coords[1] = 3.1333; user.find({ 'business_details.business_location': { $near: coords, $maxdistance: maxdistance }...

c - Error in inserting nodes in red black trees -

i trying insert nodes in red black trees. functions rotate_left, rotate_right, insertion correct rb_fixup seems wrong. red color shown 1 , black 0. have implemented algo clrs. when third element inserted gives segmentation fault. code of rb_fixup is: struct node { int data; int color; struct node *left; struct node *right; struct node *parent; }*root; rb_fixup(struct node *z) { struct node *y; y=(struct node *)malloc(sizeof(struct node)); while(z->parent->color==1) { if(z->parent==z->parent->parent->left) { y=z->parent->parent->right; if(y->color==1) { z->parent->color=0; y->color=0; z->parent->parent->color=1; z=z->parent->parent; } else if(z==z->parent->right) { z=z->parent; rotate_left(z); ...

java - How to create a navigation that open from bottom of screen? -

Image
i want create thing drawer menu open bottom of screen. thing blow image. want know special name? you can use bottomsheet library. works on android 2.1+ https://github.com/soarcn/bottomsheet

html5 - How make Wings in SVG move with css3 animations -

Image
i have wings made in svg, , want apply fly effect in .wing class, if try, animation not occurs correctly. animation in svg: svg { -webkit-animation:fly 1s linear infinite; } @-webkit-keyframes fly { 50% { -webkit-transform: rotate(20deg); } 100% { -webkit-transform: rotate(0deg); } } <?xml version="1.0" encoding="utf-8"?> <!-- generator: adobe illustrator 16.0.0, svg export plug-in . svg version: 6.00 build 0) --> <!doctype svg public "-//w3c//dtd svg 1.1//en" "http://www.w3.org/graphics/svg/1.1/dtd/svg11.dtd"> <svg version="1.1" id="layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="183px" height="159.5px" viewbox="0 0 183 159.5" enable-background="new 0 0 183 159.5" xml:space="preserve"> <g class=...

ios - Programmatically unwind segue -

Image
i displaying uiview uitableview control on it. display view show segue, calling performseguewithidentifier. in module segue called, have added function want use on unwind, retrieve data view upon return segue. right now, have done button hooked function on caller, can retrieve data segue when unwinds. instead of doing when done button tapped, when item selected in uitableview. in tableview(,willselectrowatindexpath), try calling popviewcontrolleranimated. second uiview close , bring me calling uiview, unwind function not called. i know how set unwind done button, using exit, cannot figure out how when tapping on row in uitableview. here's code i'm using execute segue: @ibaction func frombuttontap(sender: anyobject) { currentbutton = sender.tag self.performseguewithidentifier("unitssegue", sender: self) } here's code executes when segue unwound: @ibaction func returnfromunitselection(segue: uistoryboardsegue) { var buttontoset:...

javascript - Can I put a button on the tab header using Firefox Add-on? -

Image
in firefox browser window, put button on tab header next web page title. possible firefox add-on? far still unsure call part of tab. sorry duplicates! edit: didn't have reputation add images. here clarity (desired button in red) the short answer is: "yes." firefox add-ons have ability have complete control of user interface. in instance, first level of xul content want @ contained in chrome://browser/content/browser.xul . file contained within omni.ja archive in browser directory within firefox release directory. omni.ja files zip archives can view extracting files using program understands .zip archives. depending on os, may easier change extension omni.zip . within archive file chrome\browser\content\browser\browser.xul . however content need modify located in chrome://browser/content/tabbrowser.xml file (in same directory). files defines tab stack looks like. how go changing depend on type of add-on creating (e.g. overlay, restartless, add-on sd...