New Start an internet call (sip) by long pressing a number

Discussion in 'Bugs' started by Giangiva, Aug 27, 2013.

  1. Giangiva

    GiangivaMembers

    Jul 22, 2013
    174
    23
    28
    Male
    Italy
    Hello,
    in the phone app, when I long press a telephone number a list of options appear.
    Would it be possible to add "Internet call" option to that list?

    Long story:
    due to my car getting crazy about it, I had to disable the "ask for every call" option for internet calls.
    Now the internet calls are set as: "only for internet numbers".
    The problem, now, is that I cannot place any internet call for "normal" numbers (= numbers without "..@sipserver.com") unless I go again in options and change that.
    IMHO an easy way to start an internet call would be through an extra option in the list coming out by long pressing any number.
     
  2. Giangiva

    GiangivaMembers

    Jul 22, 2013
    174
    23
    28
    Male
    Italy
    Anybody knows if it would be possible to add a menu item on the phone existing app?

    Maybe I would just need some hints on how to patch it... or maybe it is more difficult than I thought.

    Thanks in any case.
     
  3. Acid

    AcidScripting Ninja
    Staff Member

    Aug 20, 2011
    2,726
    743
    245
    Male
    This might be beyond your knowledge, because you don't even have Phone or Contacts app sources. Only Xiaomi have them.
    Only option would be to hack apk
    1. Decompile Phone or Contacts apk
    2. Find a proper place in /layout or /xml files that draws that pop-up options over dialer contact numbers
    3. Find a process name (via logcat or other methods) that calls internet call functions
    4. Create a new menu entry in that place you found earlier (just copy existing code)
    5. Put there a process name that calls internet call functions.
     
  4. Giangiva

    GiangivaMembers

    Jul 22, 2013
    174
    23
    28
    Male
    Italy
    Thanks for your answer!
    I tried to open the phone.apk (it's just a zip file, after all), but I smashed my face against the xml files which are in a binary format.
    I looked for a tool to reconvert them back to their ascii format, but I had no luck.
    Can you suggest me any tool for this purpose?
    Even if will not achieve the extra menu item, I find this kind of activity very interesting, at least I can better understand how things work behind the scene.
    If I can figure out how these xml are working, I can try it.
    After all, it's """only""" a matter of adding a menu item which could jump to another menu. :)
     
  5. Acid

    AcidScripting Ninja
    Staff Member

    Aug 20, 2011
    2,726
    743
    245
    Male
    The apk must be decoded using apktool. Just search in Google.
     
  6. mimuzzle

    mimuzzleMembers

    Mar 15, 2016
    102
    28
    40
    Someone tried sip call ? It was working in miui 7 buy now I dont have internet call option
     

Share Our Site